The Artima Developer Community
Sponsored Link

Java Answers Forum
Server side form validation

0 replies on 1 page.

Welcome Guest
  Sign In

Go back to the topic listing  Back to Topic List Click to reply to this topic  Reply to this Topic Click to search messages in this forum  Search Forum Click for a threaded view of the topic  Threaded View   
Previous Topic   Next Topic
Flat View: This topic has 0 replies on 1 page
joe douglas

Posts: 3
Nickname: oaklander
Registered: Aug, 2007

Server side form validation Posted: Aug 5, 2007 6:07 PM
Reply to this message Reply
Advertisement
I want to create a JSP Form page on Tomcat with a form that has about 10 input entries where the form will validate all 10 fields and show validation errors on the same page as the original form JSP page.

For example, if someone has a blank entry on the Firstname field then it will show this message in red next to the field: First Name is required.

If the data passes the validations it will populate an Oracle database. Please advise any suggestions on how I should do this. I was thinking of submitting the fields to a Controller servlet then use the Enumeration class to get all field values where I would check for blanks. I assume if I use a bean and have a getter and setter method for each field I would then have 20 methods (10 setter and 10 getter methods) in the bean class.

I dont have Struts and need to know the best way to do this. Can anyone give me ideas or examples of how do to this?

Topic: Server side form validation Previous Topic   Next Topic Topic: Jxl, how to copy a cell value from one sheet to another sheet.

Sponsored Links



Google
  Web Artima.com   

Copyright © 1996-2019 Artima, Inc. All Rights Reserved. - Privacy Policy - Terms of Use