Create new RichFaces Documentation Jira issue

This will launch the RichFaces Jira page - to complete your feedback please login if needed, and submit the Jira.

JBoss.orgCommunity Documentation

6.4.1.  < a4j:include > available since 3.0.0

The <a4j:include> component is used to include one view as part of another and navigate there using standard JSF navigation.

Table 6.41. a4j : include attributes

Attribute Name Description
ajaxRenderedDefines, whether the content of this component must be (or not) included in AJAX response created by parent AJAX Container, even if it is not forced by reRender list of ajax action. Ignored if component marked to output by some Ajax action component. Default value is "true".
binding JSF: The attribute takes a value-binding expression for a component property of a backing bean
dirHTML: Direction indication for text that does not inherit directionality. Valid values are "LTR" (left-to-right) and "RTL" (right-to-left)
id JSF: Every component may have a unique id that is automatically created if omitted
keepTransientFlag for mark all child components to non-transient. If true, all children components will be set to non-transient state and keep in saved components tree. For output in self-renderer region all content ( By default, all content in <f:verbatim> tags and non-jsf elements in facelets, marked as transient - since, self-rendered ajax regions don't plain output for ajax processing ).
langHTML: Code describing the language used in the generated markup for this component
layoutHTML layout for generated markup. Possible values: "block" for generating an HTML <div> element, "inline" for generating an HTML <span> element, and "none" for generating no HTML element. There is a minor exception for the "none" case where a child element has the property "rendered" set to "false". In this case, we create an empty <span> element with same ID as the child element to use as a placeholder for later processing. Default value is "inline"
rendered JSF: If "false", this component is not rendered
styleHTML: CSS style rules to be applied to the component
styleClass JSF: Assigns one or more CSS class names to the component. Corresponds to the HTML "class" attribute.
titleHTML: Advisory title information about markup elements generated for this component
viewIdSpecifies the view id of a page that is included.

Table 6.42. Component identification parameters


To create the simplest variant of the component on a page use the following syntax:


      <a4j:include  viewId="/pages/include/first.xhtml" />

This component cannot be created dynamically.

The component is used to include one view as part of another and may be put anywhere in the page code. The 'viewID' attribute is used to point at the part to be included and should present a full context-relative path of the resource in order to be used as from-view and to-view in the JSF navigation cases. In general the component functions as Fecelets <ui:include> tag but with partial page navigation in Ajax mode as an advantage.

The navigation rules could look as following:



Vizit the Include page for examples of component usage and their sources.