Select

extends Zend\Form\Element implements Zend\InputFilter\InputProviderInterface

Known subclasses

Omeka\Form\Element\AbstractGroupByOwnerSelect, Omeka\Form\Element\AbstractVocabularyMemberSelect, Omeka\Form\Element\ItemSetSelect, Omeka\Form\Element\PropertySelect, Omeka\Form\Element\ResourceClassSelect, Omeka\Form\Element\ResourceSelect, Omeka\Form\Element\SiteSelect
Methods Summary
public
public
# setValueOptions( array $options )
public
# unsetValueOption( string $key )
public
# setOptions( array|\Traversable $options )
Set options for an element. Accepted options are: - label: label to associate with the element - label_attributes: attributes to use when the label is rendered - value_options: list of values and labels for the select options _ empty_option: should an empty option be prepended to the options ?

Overrides

public
# setAttribute( string $key , mixed $value )
Set a single element attribute

Overrides

public
# setDisableInArrayValidator( bool $disableOption )
Set the flag to allow for disabling the automatic addition of an InArray validator.
public
# disableInArrayValidator( )
Get the disable in array validator flag.
public
# setEmptyOption( string|null $emptyOption )
Set the string for an empty option (can be empty string). If set to null, no option will be added
public
# getEmptyOption( )
Return the string for the empty option (null if none)
protected
# getValidator( )
Get validator
public
# setUseHiddenElement( bool $useHiddenElement )
Do we render hidden element?
public
# useHiddenElement( )
Do we render hidden element?
public
# setUnselectedValue( string $unselectedValue )
Set the value if the select is not selected
public
# getUnselectedValue( )
Get the value when the select is not selected
public
# getInputSpecification( )
Provide default input rules for this element

Implementation of

protected
# getValueOptionsValues( )
Get only the values from the options attribute
protected
# getOptionValue( $key , $optionSpec )
public
# isMultiple( )
Element has the multiple attribute
Methods inherited from Zend\Form\Element
__construct(), init(), setName(), getName(), setOptions(), getOptions(), getOption(), setOption(), setAttribute(), getAttribute(), removeAttribute(), hasAttribute(), setAttributes(), getAttributes(), removeAttributes(), clearAttributes(), setValue(), getValue(), setLabel(), getLabel(), setLabelAttributes(), getLabelAttributes(), setLabelOptions(), getLabelOptions(), clearLabelOptions(), removeLabelOptions(), setLabelOption(), getLabelOption(), removeLabelOption(), hasLabelOption(), setMessages(), getMessages()
Properties Summary
protected array $attributes
Seed attributes
# array ( 'type' => 'select', )
protected Zend\Validator\ValidatorInterface $validator
# NULL
protected bool $disableInArrayValidator
# false
protected bool $emptyOption
Create an empty option (option with label but no value). If set to null, no option is created
# NULL
protected array $valueOptions
# array ( )
protected bool $useHiddenElement
# false
protected string $unselectedValue
# ''
Properties inherited from Zend\Form\Element
$attributes, $label, $labelAttributes, $labelOptions, $messages, $options, $value