MultiSelectListbox MultiSelectListbox is used to select an item from a collection of listboxes that are in parent-child relationship.
Categories
  • Group 1
    • Group 1.1
      • Option 1.1.1
      • Option 1.1.2
    • Group 1.2
      • Option 1.2.1
      • Option 1.2.2
      • Option 1.2.3
  • Group 2
    • Group 2.1
      • Option 2.1.1
  • Group 3
    • Option 3.1
    • Option 3.2
    • Option 3.3
    • Option 3.4
  • Group 4
    • Option 4.1
Value:
<h:form>
    <p:multiSelectListbox value="#{multiSelectView.selection}" effect="slide" header="Categories" showHeaders="true">
        <f:selectItems value="#{multiSelectView.categories}" />
    </p:multiSelectListbox>

    <p:commandButton value="Save" icon="ui-icon-check" update="out" style="display:block;margin:10px 0" />

    <h:outputText id="out" value="Value: #{multiSelectView.selection}" style="display:block" />
</h:form>
                
PrimeTek, Copyright © 2015
All rights reserved.
Running PrimeFaces-6.0.14 on Mojarra-2.2.8.