> From: Steve Brown <[EMAIL PROTECTED]>

> Unexpected results:
> If line 16 (indicated below) is commented out, the '?>' in the string
> on line 17 makes PHP stop parsing and the rest of the script is simply
> dumped to stdout.  If line 16 is NOT commented out, the '?>' is NOT
> picked up as being a PHP tag and it parses the script as PHP.

Quote:  The one-line comment styles actually only comment to the end of the 
line or the current block of PHP code, whichever comes first. This means that 
HTML code after // ?> WILL be printed: ?> skips out of the PHP mode and returns 
to HTML mode, and // cannot influence that. If asp_tags configuration directive 
is enabled, it behaves the same with // %>.

From: http://www.php.net/manual/en/language.basic-syntax.comments.php

I remember running into this, also, so don't feel bad about not noticing it. ;)

---John Holmes...

UCCASS - PHP Survey System
http://www.bigredspark.com/survey.html

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to