public static function Select::preRenderSelect in Drupal 9
Same name and namespace in other branches
- 8 core/lib/Drupal/Core/Render/Element/Select.php \Drupal\Core\Render\Element\Select::preRenderSelect()
Prepares a select render element.
File
- core/
lib/ Drupal/ Core/ Render/ Element/ Select.php, line 195
Class
- Select
- Provides a form element for a drop-down menu or scrolling selection box.
Namespace
Drupal\Core\Render\ElementCode
public static function preRenderSelect($element) {
Element::setAttributes($element, [
'id',
'name',
'size',
]);
static::setAttributes($element, [
'form-select',
]);
return $element;
}