Easy learning with example program codes

Jsf panelgrid html tag

JSF h:panelGrid tag is used to render HTML table element.

Attributes of h:panelGrid tag.

Attribute Description
id id for the tag
binding Reference to the component used in a backing bean
rendered A boolean value; false would suppress rendering
styleClass Cascading stylesheet (CSS) class name
value value binding
bgcolor Background color for the table
border Width of the table’s border
cellpadding Padding around table cells
cellspacing Spacing between table cells
columnClasses Comma-separated list of CSS classes for columns
columns Number of columns in the table
footerClass CSS class for the table footer
frame frame Specification for sides of the frame surrounding the table that are to be drawn; valid values: none, above, below, hsides, vsides, lhs, rhs, box, border
headerClass CSS class for the table header
rowClasses Comma-separated list of CSS classes for columns
rules Specification for lines drawn between cells; valid values: groups, rows, columns, all
summary Summary of the table’s purpose and structure used for non-visual feedback such as speech
dir Direction for text. Valid values are ltr (left to right) and rtl (right to left).
lang Base language of an element’s attributes and text
border Pixel value for an element’s border width
lang Base language of an element’s attributes and text
title A title used for accessibility. Browsers typically create tooltips for the title’s value
width Width of an element
onblur Event handler for losing focus
onchange Event handler for value changes
onclick Event handler for Mouse button clicked over the element
ondblclick Event handler for Mouse button double-clicked
onfocus Event handler for element received focus
onkeydown Event handler for Key pressed
onkeypress Event handler for Key pressed and released
onkeyup Event handler for Key released
onmousedown Event handler for Mouse button pressed
onmousemove Event handler for mouse moved
onmouseout Event handler for mouse left
onmouseover Event handler for mouse moved onto
onmouseup Event handler for mouse button released



<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" 
<html xmlns=""
		<title>JSF panel grid example.</title>
	<h3>JSF panel grid example.</h3>
	<h:panelGrid id="panel" columns="2" border="1">
		<f:facet name="header">
			<h:outputText value="Login" />
		<h:outputLabel value="UserName" />
		<h:inputText />
		<h:outputLabel value="Password" />
		<h:inputSecret />
		<f:facet name="footer">
		  <h:panelGroup style="display:block;text-align:center">
			<h:commandButton id="submit" value="Submit" />


<?xml version="1.0" encoding="windows-1252"?>
<faces-config version="2.0" 


<?xml version="1.0" encoding="UTF-8"?>
<web-app version="3.0" 




JSF example19-1
Download this example.

Sign Up/ Sign In
Ask a Question

Industrial Training

We offers Placement Oriented Training on Java, Spring, JSF, Hibernate, PHP, AngularJS, Angular 4, PLSQL, Oracle BI Publisher etc. We also provides Online training, please mail us at


We also provides the Development services for Website Development , Java Development, PHP Development, Android App Development etc. You can contact us on

Copyright © 2018 CodesJava Protection Status SiteMap Reference: Java Wiki