Input Style

Free Themes

Built-in component themes created by the PrimeFaces Theme Designer.

Saga Saga
Vela Vela
Arya Arya

Legacy Free Themes

Luna Amber Luna Amber
Luna Blue Luna Blue
Luna Green Luna Green
Luna Pink Luna Pink
Nova Nova
Nova Nova Alt
Nova Nova Accent

PREMIUM TEMPLATES

Create awesome applications in no time using the premium templates and impress your users.

Client Side Validation Event

Validations can be triggered instantly without needing a button/link click using p:clientValidator.


<div class="card">
    <h:form>
        <h:panelGrid columns="4" cellpadding="7">
            <h:outputLabel for="text" value="Text: (Change)"/>
            <p:inputText id="text" value="#{validationView.text}" required="true">
                <f:validateLength minimum="2" maximum="5"/>
                <p:clientValidator/>
            </p:inputText>
            <p:message for="text" display="icon"/>
            <h:outputText value="#{validationView.text}"/>

            <h:outputLabel for="integer" value="Integer: (Keyup)"/>
            <p:inputText id="integer" value="#{validationView.integer}">
                <p:clientValidator event="keyup"/>
            </p:inputText>
            <p:message for="integer" display="icon"/>
            <h:outputText value="#{validationView.integer}"/>
        </h:panelGrid>

        <p:commandButton value="Save" ajax="false" icon="pi pi-check" validateClient="true" styleClass="p-mt-3" />
    </h:form>
</div>