Skip to content

Instantly share code, notes, and snippets.

@swallentin
Created August 13, 2014 08:38
Show Gist options
  • Save swallentin/a0c507f03a0db54347f5 to your computer and use it in GitHub Desktop.
Save swallentin/a0c507f03a0db54347f5 to your computer and use it in GitHub Desktop.
Sample of include using Java Server Pages - Facelets
<ui:composition
xmlns="http://www.w3.org/1999/xhtml"
xmlns:f="http://java.sun.com/jsf/core"
xmlns:h="http://java.sun.com/jsf/html"
xmlns:ui="http://java.sun.com/jsf/facelets"
xmlns:fmt="http://payment.unibet.com/jsf/message">
<div class="#{cssClass}">
<h2>Include page</h2>
<p>Include page blah blah lorem ipsum</p>
<fmt:msg key="payment.euteller.depositHowLong.info" />
<span>#{eutellerDeposit.depositFeeText}</span>
</div>
</ui:composition>
<ui:composition xmlns="http://www.w3.org/1999/xhtml"
xmlns:h="http://java.sun.com/jsf/html"
xmlns:c="http://java.sun.com/jsp/jstl/core"
xmlns:ui="http://java.sun.com/jsf/facelets"
xmlns:f="http://java.sun.com/jsf/core"
xmlns:fn="http://java.sun.com/jsp/jstl/functions">
<ui:include src="/content/web/deposit/test.xhtml" >
<ui:param name="cssClass"
value="myClass" />
</ui:include>
</ui:composition>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment