You are here

protected static function Select::setSelectType in Select (or other) 8

Same name and namespace in other branches
  1. 4.x src/Element/Select.php \Drupal\select_or_other\Element\Select::setSelectType()

Sets the type of buttons to use for the select element.

Parameters

array $element: The select or other element.

1 call to Select::setSelectType()
Select::processSelectOrOther in src/Element/Select.php
Render API callback: Expands the select_or_other element type.

File

src/Element/Select.php, line 36

Class

Select
Provides a form element with a select box and other option.

Namespace

Drupal\select_or_other\Element

Code

protected static function setSelectType(array &$element) {
  $element['select']['#type'] = 'select';
}