How to Define an Action that Forwards Users to Another Page
This topic explains how to setup navigation between two JSP pages using a
navigational action in a page flow Controller class.
These instructions assume that you have a dynamic
web project (New > Project > Other > Web > Dynamic
Web Project) that contains a page flow
with at least two JSP pages.
To Create the Navigational Action
Open the Page Flow perspective (Window >
Open Perspective > Page Flow).
Right-click in the center pane of the Page Flow
Editor and select New
In the New Action
dialog, in the Action Template field, confirm that Basic
Method Action is selected.
In the Action Name field, enter an appropriate name for
the action. This will be the name of the action method.
In the Forward To field, select the destination JSP page.
(This is the page that users will navigate to.)
To Create a Link that Invokes the Navigational Action
Open the JSP page that will invoke the action. This is the starting page
that users will navigate from.
On the JSP Design Palette,
expand the NetUI category by clicking the heading or the + sign. Under
heading, drag and drop the anchor icon onto the starting
In the New Anchor dialog, in the Anchor Type
dropdown, confirm that Action is selected.
In the Text field, enter some appropriate text. This is
the display text for the hyperlink.
In the Action dropdown, select the action method you created
In the Page Flow Editor there should be two arrows:
(1) an arrow pointing from the starting JSP page to the action method and
(2) another arrow pointing from the action method to the destination JSP
The source code you have created should look something like the following:
<netui:anchor action="navAction">Navigate to destination.jsp!</netui:anchor>