This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes HTML, CSS and JavaScript and the fly likes Realtime Validation with Ajax Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Engineering » HTML, CSS and JavaScript
Bookmark "Realtime Validation with Ajax" Watch "Realtime Validation with Ajax" New topic
Author

Realtime Validation with Ajax

J Das
Ranch Hand

Joined: Jul 27, 2011
Posts: 83

Hello Ranchers.. I need to validate my forms in my web application in realtime (using Ajax), I searched the web and found the following suitable solution for my query...




The following is the servlet..



Actually i need the same thing to be done with database , but what the above example shows is with a Hashmap... anyone who can help me in this ?? I will be very grateful.. Thank You all in advance..
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 60738
    
  65

I removed the copyright notice from your servlet code because it was making the page too wide. Please take care when posting code to make sure that lines break in a reasonable width.

And, why are you putting a Sun copyright on your code?


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
J Das
Ranch Hand

Joined: Jul 27, 2011
Posts: 83

Bear Bibeault wrote:I removed the copyright notice from your servlet code because it was making the page too wide. Please take care when posting code to make sure that lines break in a reasonable width.

And, why are you putting a Sun copyright on your code?


Ooops ! Sorry, my mistake..
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 60738
    
  65

Sorry, but that is way too much code to look at. Especially without any sort of explanation as to what you are actually trying to accomplish.

Please post an SSCCE and a description of what issues you are having.
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 60738
    
  65

P.S. My recommendation is to use jQuery with the Validation plugin.
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: Realtime Validation with Ajax
 
Similar Threads
The form is not submitting
Issue regarding a basic AJAX project
XmlHttpRequest object undefined js error
parsing the xml returned from ajax call
Weblogic 10.4.5 404 Not Found