Showing posts with label primefaces 3. Show all posts
Showing posts with label primefaces 3. Show all posts

5/16/2011

4. add primfaces: Example App using Seam 3, RichFaces 4 on eclipse

Building example application seam 3 + richfaces 4 series
4. Add primefaces

1. add jar file
This is quite simple.

You can just add primefaces-3.0.M1.jar (or latest) in WebContent/WEB-INF/lib directory
, and you are ready to use it.

2. add index_primefaces.xml in WebContent directory

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
xmlns:h="http://java.sun.com/jsf/html"
xmlns:f="http://java.sun.com/jsf/core"
xmlns:p="http://primefaces.prime.com.tr/ui">
<f:view>
<h:head>
</h:head>
<h:body styleClass="page">
<h1>Primefaces test</h1>

<div>
<p:tooltip global="true"/>

<h:panelGrid columns="1" cellpadding="5">
<h:form>
<p:commandButton value="Submit" title="Click to save" type="button" />

<h:outputLink value="#" title="Go to">
<h:outputText value="Link" />
</h:outputLink>

<p:inputText title="This is a required field" />
</h:form>
</h:panelGrid>
</div>
</h:body>
</f:view>
</html>



3. deploy it onto Jboss 6

4. http://localhost:8080/seam3-test/index_primefaces.xhtml