public function OpenReadSpeakerSettingsForm::submitForm in Open ReadSpeaker 8
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/ OpenReadSpeakerSettingsForm.php, line 130
Class
- OpenReadSpeakerSettingsForm
- Class OpenReadSpeakerSettingsForm.
Namespace
Drupal\open_readspeaker\FormCode
public function submitForm(array &$form, FormStateInterface $form_state) {
parent::submitForm($form, $form_state);
$this
->config('open_readspeaker.settings')
->set('open_readspeaker_accountid', $form_state
->getValue('open_readspeaker_accountid'))
->set('open_readspeaker_i18n', $form_state
->getValue('open_readspeaker_i18n'))
->set('open_readspeaker_post_mode', $form_state
->getValue('open_readspeaker_post_mode'))
->set('open_readspeaker_url', $form_state
->getValue('open_readspeaker_url'))
->save();
Cache::invalidateTags([
'library_info',
]);
}