About facelets

Facelets is a view technology that focuses on building JSF component trees using concepts well known by Tapestry users.

Installation

Download facelets 1.0.4 release on java.net. Then extract the archive and put jsf-facelets.jar in your WEB-INF/lib folder.

Put xulfaces.taglib.xml from sample application (WEB-INF/facelet) into your WEB-INF/facelet folder.

Edit your faces configuration and add the following lines :




<application>
   	<view-handler>
		org.xulfaces.facelet.CustomFaceletViewHandler
   	</view-handler>
</application>

				

Edit your web.xml and add the following lines :




<context-param>
	<param-name>facelets.LIBRARIES</param-name>
	<param-value>/WEB-INF/facelet/xulfaces.taglib.xml</param-value>
</context-param>

				

Using facelets

Facelets deals with XHTML pages unlike JSP.

Have a look on this xulfaces sample with facelets :



			
<?xml version="1.0"?>
<!DOCTYPE window >
<?xml-stylesheet href="chrome://global/skin" type="text/css"?>
<?xml-stylesheet href="css/admin.css" type="text/css"?>
<window		
	xmlns:html="http://www.w3.org/1999/xhtml"
	xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
	xmlns:xfc="http://xulfaces.sourceforge.net/xulfaces/xul/client.xul"
	xmlns:xf="http://xulfaces.sourceforge.net/xulfaces/jsf/facelet">

	<xf:label control="test-textbox1" crop="none" value="A String"/>
	<textbox id="test-textbox1"/>
	
	<xf:bridge/>
</window>
	
				

Check facelets documentation (good work !) for further informations.

This is first realease of xulfaces supporting facelets. There must be bugs. Please report them !