#29642 [Opn->Bgs]: Incorrect string handling of "<" and "&"
| From: | derick@php.net | Date: | Fri, 13 Aug 2004 07:12:18 +0000 |
| Subject: | #29642 [Opn->Bgs]: Incorrect string handling of "<" and "&" | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-64527@lists.php.net to get a copy of this message | ||
ID: 29642
Updated by: derick@php.net
Reported By: webdevguy1 at yahoo dot com
-Status: Open
+Status: Bogus
Bug Type: Strings related
Operating System: Win2k
PHP Version: 4.3.9RC1
New Comment:
Sorry, but your problem does not imply a bug in PHP itself. For a
list of more appropriate places to ask for help using PHP, please
visit http://www.php.net/support.php as this bug system
is not the
appropriate forum for asking support questions.
Thank you for your interest in PHP.
This works fine, do a "view-source" in your browser.
Previous Comments:
------------------------------------------------------------------------
[2004-08-13 05:13:19] webdevguy1 at yahoo dot com
Description:
------------
Improper string handling of "<" and "&" characters.
Refer to test code below.
Reproduce code:
---------------
$test1a='/(?<!\\)/';
echo $test1a;
$test1b='/(?<!\\)/';
echo $test1b;
var_dump($test1b);
$test1c='/(?<!\\)/';
var_dump($test1c);
$test2a='<';
echo $test2a;
$test2b='<<br />';
echo $test2b;
$test2c='<';
var_dump($test2c);
$test2f='<';
echo $test2f;
var_dump($test2f);
$test3f='&';
echo $test3f;
var_dump($test3f);
Expected result:
----------------
test1a: /(?<!\\)/
test1b: /(?<!\\)/
test1c: string(9) "/(?<!\\)/"
test2a: <
test2b: <
test2c: string(1) "<"
test2f: <string(1) "<"
tests 3a-3e: replace "<" with "&": same results
test3f: &string(1) "&"
Actual result:
--------------
test1a outputs: /(?
test1b outputs: /(?
test1c outputs: string(8) "/(?
test2a outputs:
test2b outputs: <
test2c outputs: string(1) "<"
test2f outputs: <"
tests 3a-3e: replace "<" with "&": same results
test3f outputs: &string(1) "&"
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=29642&edit=1