Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

how to call a jsp page from another jsp in struts?

 
akash kumar
Ranch Hand
Posts: 69
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi!
How to call a jsp page from another jsp when i click the submit button in struts with out using the action class as intermediate?
[ December 26, 2007: Message edited by: akashkumar kumar ]
 
Pankaj Kap
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You can use a ForwardAction. You won't require an action to be written for this, just set your type attribute of action tag in struts-config as org.apache.struts.actions.ForwardAction. Refer example below:

<!--example starts-->
<action path="/saveSubscription" type="org.apache.struts.actions.ForwardAction"
name="subscriptionForm"
scope="request"
input="/subscription.jsp"
parameter="/path/to/jsp"/>
<!--example ends-->
[ December 26, 2007: Message edited by: Pankaj Kap ]
 
akash kumar
Ranch Hand
Posts: 69
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks Pankaj!
 
Venkat Kanneganti
Ranch Hand
Posts: 43
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
you can use <html:link> tag
 
Consider Paul's rocket mass heater.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic