I am trying to validate user inputs (free text) on a web page before the data is stored in the database. The site's written using unconvensional asp.net, as it was largely upgraded from classic asp.
I want to make sure / or protect users from entering text values along with invalid characters such html. At the moment, if the page is submitted it crashes.
Should I use the HttpUtility.HtmlEncode to correct each text box entry? Does this sound feasible?
Thanks in advance.