In the struts-config.xml try setting validate=false for the initial action
names and then set it to true for the submit action on the form of the
names.jsp . This will disable the validate() call when the form is first
initialized :
action-mappings
action
path=/app/names
Don't go to the action page (the .do), go to the .jsp page! The action
is just the target of the form, not the page you start from.
(At least that's what I've figured out?!)
Dick Starr said:
My problem is that when I execute my form via
http://localhost:8080/starrd/app/names.do I get
Since you are calling names.do directly, formbean calls validate() method before
forwarding to appropriate action class and hence the erros are displayed.
Call your form using this http://localhost:8080/starrd/pages/app/Name.jsp initially
and set action=/app/names while submitting.
I'm pretty new to struts also, but here is what I've found:
If you set validate to true in the action mapping, the validation will
run before the action. If you set it to false, you may run the validate
method of the form yourself at any time. Also, it is interesting to note
that if you
4 matches
Mail list logo