correct example

error_message is passed by ref as of 5.0.1


git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@167312 c90b9560-bf6c-de11-be94-00142212c4b1
This commit is contained in:
Friedhelm Betz 2004-08-26 17:47:30 +00:00
parent c6583b18b9
commit 321de8efc2

View file

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='iso-8859-1'?>
<!-- $Revision: 1.5 $ -->
<!-- $Revision: 1.6 $ -->
<refentry id="function.php-check-syntax">
<refnamediv>
<refname>php_check_syntax</refname>
@ -23,7 +23,7 @@
<simpara>
If the <parameter>error_message</parameter> parameter is used, it will
contain the error message from the syntax check. <parameter>error_message
</parameter> must be passed in by <link linkend="language.references">
</parameter> is passed in by <link linkend="language.references">
reference</link>.
</simpara>
<para>
@ -37,7 +37,7 @@
$error_message = "";
$filename = "./tests.php";
if(!php_check_syntax($filename, &$error_message)) {
if(!php_check_syntax($filename, $error_message)) {
printf("Errors were found in the file %s:\n\n%s\n", $filename, $error_message);
} else {
printf("The file %s contained no syntax errors.", $filename);