Validating JSP's and HTML Forms, Server-side or Client-side, or both?

Posted by CitadelCSAlum on Stack Overflow See other posts from Stack Overflow or by CitadelCSAlum
Published on 2010-05-28T21:30:00Z Indexed on 2010/05/28 21:32 UTC
Read the original article Hit count: 213

Filed under:
|
|

I am aware that I can Google "HTML Form Validation" and would get a billion tutorials. I am well aware that I can use simple JavaScript to validate form input, but I have been told that this is not necessarily an efficient method. I have also heard that it is a best practice to validate both client and server-side code. OK! Well, What exactly does this mean besides writing code on both? Does it mean I do some with JavaScript and other with Servlet's or does it mean that I write identical validation methods on both?

My real question is can anybody give me insight and direction as how to go about validation my HTML forms. I am using JSP's and Servlet's and I have tons of form validation to do.

I have already done minor form validation with regex in Java, but want to figure out if Im heading in the right track before I write any more code.

Only productive answers please, If I wanted negative feedback on how inexperienced I was, I would have gone to Reddit.

Thanks!

© Stack Overflow or respective owner

Related posts about html

Related posts about jsp