Welcome to WebmasterWorld Guest from

Forum Moderators: coopster & jatar k

Message Too Old, No Replies

str_replace ignored

9:22 am on Feb 8, 2005 (gmt 0)

Junior Member

10+ Year Member

joined:Nov 29, 2003
votes: 0

im pulling my hair out here

all im trying to do is add to a url using str_replace


$url = str_replace("abc&e","abc&d&e",$url);

but it is just ignored on the server but it works fine on my local setup.

i have tried

$url = str_replace("abc&e","abc\&d\&e",$url);

$url = str_replace("abc\&e","abc&d&e",$url);

$url = str_replace("abc&e","abc\&d\&e",$url);

$url = str_replace("abc\&e","abc\&d\&e",$url);

problem setup = php 4.3.10
local setup = php 4.3.9 (windows)

any suggestions greatly appreciated


11:17 am on Feb 8, 2005 (gmt 0)

Senior Member

WebmasterWorld Senior Member 10+ Year Member

joined:Sept 22, 2002
votes: 0

Are you sure that $url contains the same string in both situations?