I don't have some code around to do this, but you might want to check HTML::Parser or HTML::TokeParser.
The idea is to scan the user input for tags or attributes you don't want him/her to use (<SCRIPT>, <MARQUEE>, etc...), strip them and store the resulting HTML field.
<kbd>--In reply to Re: How do I test for potential security problems? (and eventually remove HTML tags)
by OeufMayo
in thread How do I test for potential security problems?
by Gryphaan
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |