Name

<h:panelGrid>

Synopsis

This action represents an instance of the component type registered with the type ID javax.faces.HtmlPanelGrid (by default, an instance of the javax.faces.component.html.HtmlPanelGrid class), combined with a renderer registered with the renderer type ID javax.faces.Grid.

The component is rendered as an HTML table with the number of columns specified by the columns attribute. The component’s children are used to render the table cells, with new rows as the number of columns is reached.

The panel component may be equipped with a header and a footer facet. The table’s header facet is rendered as one <th> element (with a colspan attribute set to the value of the columns attribute) within a <tr> element, enclosed within an <thead> element. The footer facet is rendered in a similar manner, but with a <td> element instead of <th> and a <tfoot> element instead of the <thead> element. CSS style classes for the header and footer cells can be specified by the headerClass and footerClass attributes.

The table rows are rendered within a <tbody> element, with a <tr> element for each row and a <td> element for each column. CSS style classes for the rows and cells can be specified by the rowClasses and columnClasses attributes.

Syntax

<h:panelGrid [id="id"] [binding="componentBinding"] [rendered="true|false"] 
  [columns="noOfColumns"]
  [headerClass="styleClass"] [footerClass="styleClass"] 
  [rowClasses="styleClasses"] [columnClasses="styleClasses"] <!-- HTML attributes --> [bgcolor=" ...

Get JavaServer Faces now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.