views:

142

answers:

2

On my website I have tags that people can use to post on my site and mess with it. What I would like to know is how do i make it so the browser just reviews everything in a file I write too as text. I would like it so there is no html and in certian parts of my website!

All of it is in ASP

+1  A: 

Check out http://htmlpurifier.org/. It filters HTML input with a white list of acceptable tags, so you don't get anything undesirable - like iframes, or javascript, etc. Assuming I understand your question correctly.

mabwi
A: 

The general term for what you are asking for is "HTML Sanitization" - There is actually a good discussion of this, along with some code on the StackOverflow Blog.

Mike Buckbee