Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

<html:select>box validation

 
unnii
Greenhorn
Posts: 23
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Guys,

Greetings!!

Can you please help me to validate <html:select> box in struts1.3. I just need to say error message like 'required' if one who is not selecting the list on form submission

Cheers!!!
Unnii
 
David Newton
Author
Rancher
Posts: 12617
IntelliJ IDE Ruby
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
How are you doing your validation? This sounds like a simple "required" validation.
 
unnii
Greenhorn
Posts: 23
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

i am using javascript validation like the following:

validation.xml:



put an entry in jsp like :



and entry in resource file


its working for contactname but not for country..

can you please help me ??

Cheers!!
Unnii
 
David Newton
Author
Rancher
Posts: 12617
IntelliJ IDE Ruby
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You'll have to show the form code.

AFAIK the JavaScript will work for both single- and multiple-select boxes.
 
unnii
Greenhorn
Posts: 23
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
this code is to fetch countries from DB. I need to ask the customer to select Country as mandatory field



What should i do to validate country select box??
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic