JSF Showcase
h:outputText
HtmlOutputText is a UIOutput component that renders its own value as text.Conversion Usage
The value attribute can be converted by specifying an f:converter type of child tag.
Saturday, May 03, 2025
Source Code
<ui:composition xmlns="http://www.w3.org/1999/xhtml" xmlns:h="http://xmlns.jcp.org/jsf/html" xmlns:f="http://xmlns.jcp.org/jsf/core" xmlns:ui="http://xmlns.jcp.org/jsf/facelets"> <h:outputText value="#{outputTextModelBean.today}"> <f:convertDateTime pattern="EEEE, MMM dd, yyyy" /> </h:outputText> </ui:composition>
@ManagedBean @RequestScoped public class OutputTextModelBean { public String getText() { return "This is text from a model bean property."; } public Date getToday() { return GregorianCalendar.getInstance().getTime(); } }
Liferay Faces Bridge Implementation 5.0.0 + Showcase Common 3.1.1 + Liferay Faces Util 3.4.1 + Mojarra 2.2.20