It's not a secret anymore!
The moose likes Struts and the fly likes form validate() Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login


Win a copy of The Mikado Method this week in the Agile and other Processes forum!
JavaRanch » Java Forums » Frameworks » Struts
Reply Bookmark "form validate()" Watch "form validate()" New topic
Author

form validate()

Andy Hahn
Ranch Hand

Joined: Aug 31, 2004
Posts: 225
I have a simple form and validate method. The validation works great on a text field. The problem I am having is when validate returns the action error, my form bean is not found on the request. Is this normal behavior. What happens is a logic:equal tag fails since the name attribute is my form bean name, which isn't found. Ideas?
Brent Sterling
Ranch Hand

Joined: Feb 08, 2006
Posts: 948
I would have to know a little bit more about your JSP, the exact error that you are getting, your input attribute and what the action that displays the page does to provide much help. If there are values on your form that you are populating in the action that displays the page then you might need to have your input point at an action that can do the same thing (or you can store them as hidden fields on your jsp).

- Brent
Andy Hahn
Ranch Hand

Joined: Aug 31, 2004
Posts: 225
Hey Brent, I did a complete rebuild this morning and now it works. Not sure what happened, maybe JSP caching.
 
I agree. Here's the link: http://zeroturnaround.com/jrebel - it saves me about five hours per week
 
subject: form validate()
 
Similar Threads
URGENT:Tiles giving bean not defined
I am getting error when starting Tomcat .How can I rectify it?
initialize an array of data to dynamic form bean
Issue: Form bean not being populated.
Behaviour on failure of validate in form bean