This question was caused by a typo or a problem that can no longer be reproduced. While similar questions may be on-topic h开发者_开发百科ere, this one was resolved in a way less likely to help future readers.
Closed 7 years ago.
Improve this questionI am using this but it is not working:
$replaced = str_replace(''', '"', $text);
Any help would be appreciated.
Try this:
$replaced = str_replace('\'', '"', $text);
OR
$replaced = str_replace("'", '"', $text);
$replaced = str_replace('\'', '"', $text);
str_replace(array(" ' ", " \" ", " " "), " ", htmlspecialchars($variable ) );
精彩评论