How about this:

<action  path="/maauto/quote"
              type="MyClass">
               <forward   name="success" path="/maauto/done.do"/>

<action  path="/maauto/done"
              forward="/myapp/apage.jsp"
/>


Ellen Kraffmiller wrote:
> 
> Hi,
> I have a question regarding local forwards.
> It seems that a popular way to avoid hardcoding navigation in your action
> class is to have a local forward named "success", that can be updated in
> your struts-config.xml:
> 
> <action  path="/maauto/quote"
>               type="MyClass">
>               <forward   name="success" path="/myapp/apage.jsp"/>
> </action>
> 
> What if I have multiple actions, and each one should go to /myapp/apage.jsp
> in case of "success" - do I have to hard code the path for each local
> forward?
> 
> It would be nice to be able to define a global forward, and use its logical
> name in my local forwards:
> 
> <global-forwards>
>     <forward   name="home" path="/myapp/apage.jsp"/>
> </global-forwards>
> 
> <action  path="/maauto/quote"
>               type="MyClass">
>               <forward   name="success" path="home"/>
> </action>
> 
> I haven't seen anything in the docs that says this is allowed. Maybe there's
> some other way of using a logical name for the success forward, rather than
> hard coding it?
> 
> Thanks,
> Ellen
> 
> _________________________________________________________________
> Get your FREE download of MSN Explorer at http://explorer.msn.com

-- Ted Husted, Husted dot Com, Fairport NY USA.
-- Custom Software ~ Technical Services.
-- Tel 716 737-3463.
-- http://www.husted.com/about/struts/

Reply via email to