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.

Ajax Framework Dropdown

Dependent dropdowns implemented with p:ajax behavior.

Select a Location


<div class="card">
    <h:form>
        <p:growl id="msgs" showDetail="true" skipDetailIfEqualsSummary="true"/>

        <p:panel header="Select a Location" style="margin-bottom:10px;">
            <h:panelGrid columns="2" cellpadding="5">
                <p:outputLabel for="country" value="Country: "/>
                <p:selectOneMenu id="country" value="#{dropdownView.country}" style="width:150px">
                    <p:ajax listener="#{dropdownView.onCountryChange}" update="city"/>
                    <f:selectItem itemLabel="Select Country" itemValue="" noSelectionOption="true"/>
                    <f:selectItems value="#{dropdownView.countries}"/>
                </p:selectOneMenu>

                <p:outputLabel for="city" value="City: "/>
                <p:selectOneMenu id="city" value="#{dropdownView.city}" style="width:150px">
                    <f:selectItem itemLabel="Select City" itemValue="" noSelectionOption="true"/>
                    <f:selectItems value="#{dropdownView.cities}"/>
                </p:selectOneMenu>
            </h:panelGrid>

            <p:separator/>

            <p:commandButton value="Submit" update="msgs" action="#{dropdownView.displayLocation}"
                             icon="pi pi-check"/>
        </p:panel>
    </h:form>
</div>