This is straight from  BEA doc
"An object of this type is returned from an action methods in a PageFlowController to determine the next URI to be displayed. It is constructed on the name of a forward defined by the @jpf:forward tag, and resolves to the URI specified in that forward"

The name of the variable forward's name (sucesss,failure,fred) paths you to the URI identitied to the path of the associated forward via the supplied name attribute 'success' and 'failure' are used as they are relatively easy forward names to remember
You may even code these programmatically thru setForward
Take a look at ActionForward doc for your implementation
http://struts.apache.org/api/org/apache/struts/config/ActionConfig.html#getForward()
HTH,
Martin
----- Original Message ----- From: "Paul Goepfert" <[EMAIL PROTECTED]>
To: "Struts Users Mailing List" <user@struts.apache.org>
Sent: Sunday, June 12, 2005 11:10 PM
Subject: Re: Having ttruble with actions and buttons


I am still new too struts so I don't understand why I would need to incluide forwards with names of success and failure in my struts-config. Those forward names just look like their just general forward names that have no real effect on where the page goes. Am I wrong in my thinking?

-Paul
Martin Gainty wrote:

Paul-
you need forwards defined for both success and failure name identified such as what you see in the struts doc http://struts.apache.org/userGuide/building_controller.html e.g. struts-config.xml
<!-- Edit mail subscription -->
<action
   path="/editSubscription"
   type="org.apache.struts.webapp.example.EditSubscriptionAction"
   name="subscriptionForm"
   scope="request"
   validate="false">
   <forward
       name="failure"
       path="/mainMenu.jsp"/>
   <forward
       name="success"
       path="/subscription.jsp"/>
</action>
HTH,
Martin-

----- Original Message ----- From: "Paul Goepfert" <[EMAIL PROTECTED]>
To: <user@struts.apache.org>
Sent: Sunday, June 12, 2005 9:37 PM
Subject: Having ttruble with actions and buttons


Ok, here is the problem. When I load up my web app the page loads fine. When I try to advance to another web page in my web app all I get is a blank screen. For every page I have a form.java and an action.java file so I can move through the web app. Here is part of my struts-config file that handles the actions.

<action path="/Menu"
                type="actions.MenuAction"
                name="menuForm"
                scope="request">
          <forward name="enterInfo"
                   path="/info.vm" />
          <forward name="default"
                   path="/results.vm" />
          <forward name="sort"
                   path="/sort.vm" />
</action>

In the form.java files I have getters and setters for the information I pass through the address bar. In the action.java files I have method calls to my logic for the program as well as forwards for the next page I wannt to go to.

If anyone can help me out that would be great. If more information is needed let me know.

-Paul

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to