#34145 [Opn->Bgs]: str_replace() malfunction?

From: Date: Tue, 16 Aug 2005 07:47:57 +0000
Subject: #34145 [Opn->Bgs]: str_replace() malfunction?
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-83628@lists.php.net to get a copy of this message
ID: 34145 Updated by: johannes@php.net Reported By: haoyu dot guo at ocef dot org -Status: Open +Status: Bogus Bug Type: Strings related Operating System: Redhat 9 PHP Version: 4.4.0 New Comment: 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 . Previous Comments: ------------------------------------------------------------------------ [2005-08-16 09:22:50] haoyu dot guo at ocef dot org Correction: Actual result: -------------- nothing (on web) <b (command line) ------------------------------------------------------------------------ [2005-08-16 09:21:38] haoyu dot guo at ocef dot org Description: ------------ The following code prints nothing while run from web (Apache 2), while it does print "<b" at command line. Could it be a bug or is that something I don't know? <?php $idg = "<a"; $idg = str_replace("a", "b", $idg); print $idg; ?> Reproduce code: --------------- <?php $idg = "<a"; $idg = str_replace("a", "b", $idg); print $idg; ?> Expected result: ---------------- <b (on web) <b (command line) Actual result: -------------- nothing (on web) <a (command line) ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=34145&edit=1

« previous php.bugs (#83628) next »