str_replace help!!!

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
AznFuman
Forum Newbie
Posts: 6
Joined: Fri Apr 02, 2004 3:20 pm

str_replace help!!!

Post by AznFuman »

i want to use str_replace ("$a", "", $temp_string);
if i want to replace anything that is NOT $a.
what do i do?

thanks
User avatar
markl999
DevNet Resident
Posts: 1972
Joined: Thu Oct 16, 2003 5:49 pm
Location: Manchester (UK)

Post by markl999 »

if i want to replace anything that is NOT $a
Not sure what you mean exactly, if you replace everything that is NOT $a with '', you'd just be left with $a (or multiple $a's) :o
User avatar
m3mn0n
PHP Evangelist
Posts: 3548
Joined: Tue Aug 13, 2002 3:35 pm
Location: Calgary, Canada

Post by m3mn0n »

[php_man]str_replace[/php_man]()
Post Reply