Page 1 of 1

str_replace dynamic problem

Posted: Wed Apr 13, 2005 1:22 am
by potato
Can somebody tell me why this isn't working?
I want to cut the string out of the content.
If i type the $string as a word, not a variabel, it works.
Is there any way to do that?

$content = str_replace($string,'',$content);

many thanks

Posted: Wed Apr 13, 2005 4:27 am
by Wayne
are you sure that $string is set before the str_replace function is called?

what is the error you get?