UI-Component Sets
Project Documentation


Tag name: <f:selectItems>
UIComponent class: javax.faces.component.UISelectItems
Tag class: org.apache.myfaces.taglib.core.SelectItemsTag
Facelet Tag Handler: org.apache.myfaces.view.facelets.tag.jsf.core.SelectItemsHandler
Component type: javax.faces.SelectItems
Component family: javax.faces.SelectItems

This tag associates a set of selection list items with the nearest parent UIComponent. The set of SelectItem objects is retrieved via a value-binding.

Unless otherwise specified, all attributes accept static values or EL expressions.

UISelectItems should be nested inside a UISelectMany or UISelectOne component, and results in the addition of one ore more SelectItem instance to the list of available options for the parent component


Name Type Supports EL? Description
binding javax.faces.component.UISelectItems Only EL Identifies a backing bean property (of type UIComponent or appropriate subclass) to bind " + "to this component instance. This value must be an EL expression.
id String Yes Get a string which uniquely identifies this UIComponent within the scope of the nearest ancestor NamingContainer component. The id is not necessarily unique across all components in the current view.
itemDescription String Yes The description of the current item.
itemDisabled boolean Yes Determines if the current item is selectable or not.
itemLabel String Yes The label of the current item.
itemLabelEscaped boolean Yes Determines if the rendered markup for the current item receives normal JSF HTML escaping or not.
itemValue Object Yes The value for the current item.
value Object Yes The initial value of this component.
var String No Name of a request-scope attribute under which the current item of the collection, array, etc. of the value attribute will be exposed so that it can be referred to in EL for other attributes of this component.

Facelets Attributes

Name Type Required Description
noSelectionValue false Is either an EL expression pointing to the element in the value collection whose value should be marked as a "no selection" item, or a literal string that exactly matches the value of the item in the collection that must be marked as the "no selection" item. If the user selects such an item and the field is marked as required, then it will not pass validation.