function FilterDisableForm::submitForm
Same name in other branches
- 9 core/modules/filter/src/Form/FilterDisableForm.php \Drupal\filter\Form\FilterDisableForm::submitForm()
- 10 core/modules/filter/src/Form/FilterDisableForm.php \Drupal\filter\Form\FilterDisableForm::submitForm()
- 11.x core/modules/filter/src/Form/FilterDisableForm.php \Drupal\filter\Form\FilterDisableForm::submitForm()
Overrides EntityForm::submitForm
File
-
core/
modules/ filter/ src/ Form/ FilterDisableForm.php, line 47
Class
- FilterDisableForm
- Provides the filter format disable form.
Namespace
Drupal\filter\FormCode
public function submitForm(array &$form, FormStateInterface $form_state) {
$this->entity
->disable()
->save();
$this->messenger()
->addStatus($this->t('Disabled text format %format.', [
'%format' => $this->entity
->label(),
]));
$form_state->setRedirectUrl($this->getCancelUrl());
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.