.oO(Gary White)
>On Sat, 11 Oct 2008 16:19:02 +0100, David Powers
<david@example.com>
>wrote:
>
>>Use either strip_tags() or htmlentities():
>>
>>
http://docs.php.net/manual/en/function.strip-tags.php
>>
http://docs.php.net/manual/en/function.htmlentities.php
>
>Or compare the results of the strip_tag() function with
what was
>posted and generate an error if they don't match.
But maybe sometimes you want to allow HTML as part of the
message (for
example to give code examples). I would simply call
htmlspecialchars()
on the output, that's enough.
Micha