File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Struts and the fly likes Struts 2: forward from jsp to another Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "Struts 2: forward from jsp to another" Watch "Struts 2: forward from jsp to another" New topic

Struts 2: forward from jsp to another

paddy Mahadeva Iyer
Ranch Hand

Joined: Feb 10, 2007
Posts: 63
Hi guys,

I am back with a new problem.

I have a jsp in which if i click a button i want to forward to another jsp. I know i can use 'ServletDispatcher'. But in the project all calls to jsp are in the struts.xml.

So in my case. I don't have any logic for my action method (i dn't need that method at all). So how can i avoid going to the action class and forward to my next jsp from struts.xml?
David Newton

Joined: Sep 29, 2008
Posts: 12617

If you have no "class" attribute in the action mapping the default ActionSupport class is used.
I agree. Here's the link:
subject: Struts 2: forward from jsp to another
Similar Threads
URL getting loaded twice
struts2 validation result input cannot be an action?
problem in displaying actionerrors
Perennial Prepopulation Question
Doubt on action objects' instantiation.