DesignersToolz
04-01-2004, 08:15 PM
I am using this code to stop parsing of posted code on my forum:
$threadd = str_replace("<br />","<br/>",htmlspecialchars(nl2br($thread)));
Works great. Untill someone posts a single quote.
Example of the problem:
user posts: don't
post comes out as: don\'t
Same with double quotes.
Whats up with this?
Thanks. :cool:
$threadd = str_replace("<br />","<br/>",htmlspecialchars(nl2br($thread)));
Works great. Untill someone posts a single quote.
Example of the problem:
user posts: don't
post comes out as: don\'t
Same with double quotes.
Whats up with this?
Thanks. :cool: