public function AntibotSettings::submitForm in Antibot 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/ AntibotSettings.php, line 59
Class
- AntibotSettings
- Class AntibotSettings.
Namespace
Drupal\antibot\FormCode
public function submitForm(array &$form, FormStateInterface $form_state) {
parent::submitForm($form, $form_state);
$this
->config('antibot.settings')
->set('form_ids', explode("\r\n", $form_state
->getValue('form_ids')))
->set('show_form_ids', (bool) $form_state
->getValue('show_form_ids'))
->save();
}