HTML and CSS Reference
the JSF (implicit and rule-based) navigation can be performed using
1. <h:commandButton> and <h:commandLink> via the action attribute.
2. <h:button> and <h:link> via the outcome attribute.
Both the action and the outcome attributes can accept a String literal or an eL expression, which refers to a method
that returns a String (in the case of the action attribute) or an eL expression that evaluates to a String (in the case of the
The <from-view-id> element can also be omitted, as shown in Listing 2-31.
Listing 2-31. Rule-Based Navigation Example 3
When the <from-view-id> element is omitted, this means that the navigation cases will be available for all
the pages of the application which means that for Listing 2-31, when the return result of the action or outcome
attributes of the components in any page is matched with the <from-outcome> value, the corresponding navigation
case will fire.
■ It is important to know that the navigation cases are executed in the order of their presence inside the
One of the nice features of the JSF navigation is the support of the wildcards in the <from-view-id> element. This
can be useful if you want to apply a navigation rule on a set of pages in the JSF application. Listing 2-32 shows an example.
Listing 2-32. Rule-Based Navigation Example 4
Search WWH ::