|
Posted by Mad Hatter on 09/28/12 11:49
I'm trying to replace characters in a string but getting totally confused.
I want to strip \r off the end of a string. Example, sometext\r and I want
to remove the \r
I've tried the following variations plus a few others :-
$testname=eregi_replace('\r',"",$testname);
$testname=eregi_replace('\\r',"",$testname);
$testname=eregi_replace('[\r]',"",$testname);
Nothing works as I want it. All I want is to remove all \r (and all \r but
once I get one woriing I should be able to get the other) off an inputed
string.
The php.net web site has confused me even more.Help?
Navigation:
[Reply to this message]
|