This week's book giveaway is in the OCMJEA forum.
We're giving away four copies of OCM Java EE 6 Enterprise Architect Exam Guide and have Paul Allen & Joseph Bambara on-line!
See this thread for details.
The moose likes Struts and the fly likes Can I make a global forward pointing to an  Action? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of OCM Java EE 6 Enterprise Architect Exam Guide this week in the OCMJEA forum!
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "Can I make a global forward pointing to an  Action?" Watch "Can I make a global forward pointing to an  Action?" New topic
Author

Can I make a global forward pointing to an Action?

Timothy Sam
Ranch Hand

Joined: Sep 18, 2005
Posts: 746
This thing won't work with me when I call <logic:redirect forward="buildDepartments"/>



any ideas? Thanks!


SCJP 1.5
http://devpinoy.org/blogs/lamia/ - http://everypesocounts.com/
Merrill Higginson
Ranch Hand

Joined: Feb 15, 2005
Posts: 4864
Change:

path="/WEB-INF/classes/actions/DepartmentBuilder"

to

path="/DepartmentBuilder.do"

This is assuming that "/DepartmentBuilder" is specified as the path when you defined the action in the struts-config.xml file.

If you use this technique, you callthe action the same way you would call it from the URL line in the browser. Remember: It isn't a class you're calling, it's a URI.


Merrill
Consultant, Sima Solutions
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: Can I make a global forward pointing to an Action?