Java Reference
In-Depth Information
<p:menuitem value="Documentation"
<p:menuitem value="Forum"
url="" />
<p:menuitem value="Themes"
html" />
<p:layoutUnit position="center">
Welcome to PrimeFaces
To use PrimeFaces components in our JSF pages, we need to use the
xmlns:p="" namespace. NetBeans automatically
adds this namespace to the generated page.
Notice that the rendered page is divided into sections (a header, footer, left hand-
side menu, and the main content area of the application). Normally, we would have
to use HTML <div> tags and CSS to create a layout like this. PrimeFaces, however,
includes the <p:layout> component that takes care of all the difficult tasks for us.
Inside <p:layout> , we need to have some nested <p:layoutUnit> components to
create specific sections for the page. The <p:layoutUnit> element has a position
attribute that we can use to specify what section the layout unit corresponds to:
• A value of north will result in the layout unit being rendered at the top
of the page. The width of the section will automatically cover all available
horizontal space in the browser window. This value is used to generate the
Header section in the NetBeans-generated markup.
Search WWH ::

Custom Search