This week's book giveaway is in the Clojure forum.
We're giving away four copies of Clojure in Action and have Amit Rathore and Francis Avila on-line!
See this thread for details.
Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

passing dynamic parameter in redirect

 
R .sourav nayak
Ranch Hand
Posts: 67
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi,
could some one send me some example how to pass dynamic parameter in redirect.

hoping some one to answer this
thanks
 
robert isidorson
Greenhorn
Posts: 19
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
For example :
ActionForward forward = new ActionForward("/youraction.do?id="+id,);
forward.setRedirect(true);
return forward;

You can also check out the ActionRedirect class in the documentation.
 
Brent Sterling
Ranch Hand
Posts: 948
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
A "feature" of Struts is that an ActionForward returned from findForward cannot be modified. Below is a utility method that I put together a while back to make it easy to add a dynamic parameter to an ActionForward.



- Brent
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic