public function Custom::preRenderCustomForm in Drupal 10
Same name and namespace in other branches
- 8 core/modules/views/src/Plugin/views/field/Custom.php \Drupal\views\Plugin\views\field\Custom::preRenderCustomForm()
- 9 core/modules/views/src/Plugin/views/field/Custom.php \Drupal\views\Plugin\views\field\Custom::preRenderCustomForm()
Prerender function to move the textarea to the top of a form.
Parameters
array $form: The form build array.
Return value
array The modified form build array.
File
- core/
modules/ views/ src/ Plugin/ views/ field/ Custom.php, line 84
Class
- Custom
- A handler to provide a field that is completely custom by the administrator.
Namespace
Drupal\views\Plugin\views\fieldCode
public function preRenderCustomForm($form) {
$form['text'] = $form['alter']['text'];
$form['help'] = $form['alter']['help'];
unset($form['alter']['text']);
unset($form['alter']['help']);
return $form;
}