public function SettingsForm::submitForm in Lightning Media 8
Same name and namespace in other branches
- 8.4 src/Form/SettingsForm.php \Drupal\lightning_media\Form\SettingsForm::submitForm()
- 8.2 src/Form/SettingsForm.php \Drupal\lightning_media\Form\SettingsForm::submitForm()
- 8.3 src/Form/SettingsForm.php \Drupal\lightning_media\Form\SettingsForm::submitForm()
Form submission handler.
Parameters
array $form: An associative array containing the structure of the form.
\Drupal\Core\Form\FormStateInterface $form_state: The current state of the form.
Overrides ConfigFormBase::submitForm
File
- src/
Form/ SettingsForm.php, line 42
Class
- SettingsForm
- The settings form for controlling Lightning Media's behavior.
Namespace
Drupal\lightning_media\FormCode
public function submitForm(array &$form, FormStateInterface $form_state) {
$this
->config('lightning_media.settings')
->set('entity_embed.choose_display', (bool) $form_state
->getValue('choose_display'))
->save();
parent::submitForm($form, $form_state);
}