Hi y'all

Thought I would share a buglet with you.
In PHP 4, we now have the 'heredoc' syntax, a la Perl.
Unfortunately, there is a slight bug with it. If you follow the
statement-ending semi-colon with anything other than the 'return' character
(even white space), you'll get a parse error at the next evaluation of the
variable you assigned to the heredoc. Typically, the following won't work:

$query = <<< SQL
  SELECT parentID
  FROM messages
  WHERE msgID = $_msgID
SQL;  // can't put a comment (or anything else!) here

Just thought you should know - it doesn't seem to be documented...



-- 
PHP Windows Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to