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 Struts and the fly likes Struts validations - depends= 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 » Frameworks » Struts
Bookmark "Struts validations - depends="integer"" Watch "Struts validations - depends="integer"" New topic
Author

Struts validations - depends="integer"

anu ramk
Greenhorn

Joined: Feb 26, 2004
Posts: 3
Hi,
I am amazed to find out that the built-in validator rules for "integer" doesn't catch a value of all spaces.
I had this validations.xml where I put in depends="integer" and it gave the expected error messages for all erroneous inputs containing alphabets, *, & etc.. it even caught " 6"... but it doesn't seem to validate the field when i space it out..
Is this the way struts validations are supposed to behave...? Any ideas?
 
Consider Paul's rocket mass heater.
 
subject: Struts validations - depends="integer"
 
Similar Threads
display validation message as an alert in jsp which uses struts 2 validation.xml
validate integer works but double doesn't
This weeks giveaway
validator, same field, same formbean, diff JSP,diff validations
struts validator. stoping on first validation error.