function ImageStyleDeleteForm::getReplacementOptions
Same name in other branches
- 9 core/modules/image/src/Form/ImageStyleDeleteForm.php \Drupal\image\Form\ImageStyleDeleteForm::getReplacementOptions()
- 10 core/modules/image/src/Form/ImageStyleDeleteForm.php \Drupal\image\Form\ImageStyleDeleteForm::getReplacementOptions()
- 11.x core/modules/image/src/Form/ImageStyleDeleteForm.php \Drupal\image\Form\ImageStyleDeleteForm::getReplacementOptions()
Returns a list of image style replacement options.
Return value
array An option list suitable for the form select '#options'.
2 calls to ImageStyleDeleteForm::getReplacementOptions()
- ImageStyleDeleteForm::form in core/
modules/ image/ src/ Form/ ImageStyleDeleteForm.php - Gets the actual form array to be built.
- ImageStyleDeleteForm::getDescription in core/
modules/ image/ src/ Form/ ImageStyleDeleteForm.php - Returns additional text to display as a description.
File
-
core/
modules/ image/ src/ Form/ ImageStyleDeleteForm.php, line 79
Class
- ImageStyleDeleteForm
- Creates a form to delete an image style.
Namespace
Drupal\image\FormCode
protected function getReplacementOptions() {
if (!isset($this->replacementOptions)) {
$this->replacementOptions = array_diff_key(image_style_options(), [
$this->getEntity()
->id() => '',
]);
}
return $this->replacementOptions;
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.