note 34865 added to function.str-replace
| From: | mstyle-php at mstyle dot nl | Date: | Fri, 08 Aug 2003 21:10:38 +0000 |
| Subject: | note 34865 added to function.str-replace | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-53672@lists.php.net to get a copy of this message | ||
about stripping '\' (backslashes) ,by accident this one line of code did the trick for me:
$string=str_replace("\\", "", $string);
text that got displayed like:
hi, i\'ts a weid backslash thing isn\'t it.
became:
hi, i'ts a weird backslash thing isn't it.
i hope someone can benefit from it like i did.
----
Manual Page -- http://www.php.net/manual/en/function.str-replace.php
Edit Note -- http://master.php.net/manage/user-notes.php?action=edit+34865
Delete Note -- http://master.php.net/manage/user-notes.php?action=delete+34865&report=yes
Reject Note -- http://master.php.net/manage/user-notes.php?action=reject+34865&report=yes