public function ConfigForm::submitForm in Auto Login URL 8
Same name and namespace in other branches
- 2.x src/Form/ConfigForm.php \Drupal\auto_login_url\Form\ConfigForm::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/ ConfigForm.php, line 81
Class
Namespace
Drupal\auto_login_url\FormCode
public function submitForm(array &$form, FormStateInterface $form_state) {
$values = $form_state
->getValues();
$config = $this
->config('auto_login_url.settings');
$config
->set('secret', $values['auto_login_url_secret'])
->save();
$config
->set('expiration', $values['auto_login_url_expiration'])
->save();
$config
->set('delete', $values['auto_login_url_delete_on_use'])
->save();
$config
->set('token_length', $values['auto_login_url_token_length'])
->save();
parent::submitForm($form, $form_state);
}