php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #30634 // Doesn't completely comment out certain lines
Submitted: 2004-10-31 21:33 UTC Modified: 2004-11-01 03:25 UTC
From: tonglebeak at gmail dot com Assigned:
Status: Not a bug Package: Unknown/Other Function
PHP Version: * OS: *
Private report: No CVE-ID: None
View Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
If you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: tonglebeak at gmail dot com
New email:
PHP Version: OS:

 

 [2004-10-31 21:33 UTC] tonglebeak at gmail dot com
Description:
------------
For lines, with I guess certain strings or something in them, the // will fail to completely comment out a line. Not sure how to exactly describe it, so just go by the code I give you.

Note: the comment might wrap on this screen, but that's all 1 single line.

Reproduce code:
---------------
<?

//$settings=(stristr($_SERVER['HTTP_USER_AGENT'],'MSIE') || stristr($_SERVER['HTTP_USER_AGENT'],'Googlebot')) ? '':'<?xml version="1.0" encoding="utf-8"?>' .NL. '';

?>


Expected result:
----------------
Nothing should occur with that line.

Actual result:
--------------
For some reason, "' .NL. '' ?>" is outputted.

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2004-10-31 21:41 UTC] helly@php.net
Thank you for taking the time to write to us, but this is not
a bug. Please double-check the documentation available at
http://www.php.net/manual/ and the instructions on how to report
a bug at http://bugs.php.net/how-to-report.php

.
 [2004-11-01 03:12 UTC] tonglebeak at gmail dot com
Apparently, my report wasn't read correctly. Lemme just link you to the output and the code:

output: http://turkeybot.info/dst.php

code: http://turkeybot.info/blah.txt
 [2004-11-01 03:25 UTC] helly@php.net
Thank you for taking the time to write to us, but this is not
a bug. Please double-check the documentation available at
http://www.php.net/manual/ and the instructions on how to report
a bug at http://bugs.php.net/how-to-report.php

Please read the documentation and don't reopen this bug. Fix your code. Your comment contains '?>'
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Tue Nov 05 00:01:27 2024 UTC