6.5.1. < a4j:page > available since 3.0.0

### Create new RichFaces Documentation Jira issue

Summary
255 characters left
Description
Environment
This will launch the RichFaces Jira page - to complete your feedback please login if needed, and submit the Jira.

JBoss.org Community Documentation

- Prev
- Next

### 6.5.1. < a4j:page > available since 3.0.0

expand all

#### 6.5.1.1. Description

The <a4j:page> component encodes the full HTML-page structure and used for solving some incompatibility in JSP environment with MyFaces in early Ajax4Jsf versions.

#### 6.5.1.2. Details of Usage

The component solves the problem with MyFaces for early Ajax4Jsf versions: in MyFaces implementation the <f:view> JSP tag doesn't get control for encoding contents during the RENDER_RESPONSE phase, thus Ajax can't neiher get a control nor make a response. The <a4j:page> solves this problem by wrapping the Ajax updatable areas. In the last versions of both frameworks the problem is successfully fixed and no <a4j:page> usage is required.

The component uses facet "head" for defining the contents corresponding to the HTML HEAD. There is no need to use "body" facet in order to define first body section. The attribute "format" defines page layout format for encoding DOCTYPE. The attribute "pageTitle" is rendered as title section.

According to the described above, the component defined at page as following

    <a4j:page format="xhtml" pageTitle="myPage">

          <f:facet name="head">

                <!--Head Content here-->

          </f:facet>

          <!--Page Content Here-->

    </a4j:page>

will be rendered on a page as

    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">

    <html>

        <head>

            <title>myPage</title>

            <!--Head Content here-->

        </head>

        <body>

            <!--Page Content Here-->

        </body>

    </html>

#### 6.5.1.3. Reference Data

Table of <a4j:page> attributes.

Table 6.25. Component Identification Parameters

Name | Value
--- | ---
component-type | org.ajax4jsf.components.Page
component-family | org.ajax4jsf.components.AjaxRegion
component-class | org.ajax4jsf.component.html.HtmlPage
renderer-type | org.ajax4jsf.components.AjaxPageRenderer

Table 6.26. Facets

Facet name | Description
--- | ---
head | Defines a head content

#### 6.5.1.4. Relevant Resources Links

Visit the AjaxPage page at RichFaces LiveDemo for examples of component usage and their sources.

- Prev6.5. Ajax Miscellaneous
- Top of page
- Front page
- Next6.5.2. < a4j:portlet > ...