Win a copy of Murach's Python Programming this week in the Jython/Python forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

on lost focus of textbox. + JSP + Server side Validation.  RSS feed

 
Jigar Naik
Ranch Hand
Posts: 762
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have 2 textbox in my .JSP file.

text1 & text2

I will enter some value in text1 and when the focus of text1 is lost, I want to check the value in my database table wather it is in database or not.

can anybody suggest me on same.
What technique should i use ?
I don't have any idea of how to do it...
The database table contains more than 100000 entries for that field.
I'm Using MVC architecture...
 
Joel Jorgensen
Greenhorn
Posts: 22
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'd strongly recommend making an Ajax request to the Controller, with the value of Text1. Configure the Controller so that it will pass the Text1 value to the Model, which should then verify whether the Text1 value is in the database and return true or false to the View.
[ January 08, 2007: Message edited by: Joel Jorgensen ]
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!