File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Struts Validation

 
J Abraham
Ranch Hand
Posts: 101
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi ,
In my application I am using single actionform for three JSP pages. I
want to validate the form and any error should come to the same jsp
page. I am using only one action tag for each action form. Also I am
passing some dynamic parameters to the JSP pages.

Struts-config supports only one JSP page as 'input' for one 'action' tag.
Can any body help me how to do this without making multiple action
forms.

Thanks in advance,
 
Marc Peabody
pie sneak
Sheriff
Posts: 4727
Mac Ruby VI Editor
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Create multiple ActionMappings. Each mapping can use the same Action and/or ActionForm but with unique forwards and/or inputs. This will not create any more objects than you are already doing.
 
J Abraham
Ranch Hand
Posts: 101
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thank you for your reply.

But i am having another problem. I am passing some parameters dynamically to the actions, like users.do?method=edit&user_id=1. The user id is taken dynamically.

Thanks
 
Marc Peabody
pie sneak
Sheriff
Posts: 4727
Mac Ruby VI Editor
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
so.... what's the problem?
 
J Abraham
Ranch Hand
Posts: 101
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
So, How can i pass values dynamically to the action input?

Thanks
 
Marc Peabody
pie sneak
Sheriff
Posts: 4727
Mac Ruby VI Editor
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
request.getParameter();
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic