robert_gsfame Posted September 28, 2010 Share Posted September 28, 2010 I have this $string=<span style=\"font-weight: bold;"> how can i replace the \" with " only i try this but didnt work str_replace("\\\"","\"",$string) Link to comment https://forums.phpfreaks.com/topic/214600-str_replace-small-problem/ Share on other sites More sharing options...
Chris92 Posted September 28, 2010 Share Posted September 28, 2010 I don't think you need to? try this: $str = "<span style=\"font-weight: bold\">"; echo str_replace( '\"', '"', $str ); Link to comment https://forums.phpfreaks.com/topic/214600-str_replace-small-problem/#findComment-1116677 Share on other sites More sharing options...
robert_gsfame Posted September 28, 2010 Author Share Posted September 28, 2010 thx a lot chris92! works well! Link to comment https://forums.phpfreaks.com/topic/214600-str_replace-small-problem/#findComment-1116680 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.