Possible Duplicate:
How to prevent XSS with HTML/PHP?
I know that in a lot of website, if you enter :
<script>alert("xss");</script>
The website will display an error.
Exemple : http://www.igossips.com
Enter the preceding code in the search box.
The website displays a lot of the code.
How can I prevent this to happen on my own website ??
Here is a good overview on XSS prevention:
https://www.owasp.org/index.php/XSS_%28Cross_Site_Scripting%29_Prevention_Cheat_Sheet