aspose file tools
The moose likes Struts and the fly likes How to find out which form generated errors ? 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 "How to find out which form generated errors ?" Watch "How to find out which form generated errors ?" New topic
Author

How to find out which form generated errors ?

Sreedevi Vinod
Ranch Hand

Joined: Jan 17, 2005
Posts: 117
I have a login form and a registration form on the same JSP page. I have server side validations attached to both. I'm using <html:errors> tag to print out the validation errors. I want the validation errors returned by the login form to appear in the area above it, and those returned by the registration form to appear above it. When I use <html:errors> at both places, the same errors are printed at both places when any one form fails validation. How can I write code to detect which form caused the error, so that the errors appear only at the right place ?

Thanks
Devi
Merrill Higginson
Ranch Hand

Joined: Feb 15, 2005
Posts: 4864
See the section entitled "Displaying Messages" in this link.


Merrill
Consultant, Sima Solutions
Sreedevi Vinod
Ranch Hand

Joined: Jan 17, 2005
Posts: 117
Thanks so much for the link. My problem is solved.

-Devi
 
I agree. Here's the link: http://ej-technologies/jprofiler - if it wasn't for jprofiler, we would need to run our stuff on 16 servers instead of 3.
 
subject: How to find out which form generated errors ?
 
Similar Threads
Struts (v1.1b3) html:errors property attribute?
Infinate loop between JSP and Servlet - getParameter scope appears to be indefinate
Advice on a putting dynamic message on jsp page depending on action taken by user
html:errors
please HELP html:errors in struts's jsp