Re: ereg_replace

From: Date: Tue, 10 Feb 2004 18:02:10 +0000
Subject: Re: ereg_replace
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-177302@lists.php.net to get a copy of this message
On Wednesday 11 February 2004 01:55, Nicole Lallande wrote: > Can anyone tell me why this does not work: > > $str1=ereg_replace("index.php?src=","index/",$url); Because '.' and '?' have special meanings in a regex. > is there another way to do this? If it's a plain simple string replace you want then use str_replace(). -- Jason Wong -> Gremlins Associates -> www.gremlins.biz Open Source Software Systems Integrators * Web Design & Hosting * Internet & Intranet Applications Development * ------------------------------------------ Search the list archives before you post http://marc.theaimsgroup.com/?l=php-general ------------------------------------------ /* The Gordian Maxim: If a string has one end, it has another. */

« previous php.general (#177302) next »