You are here

function extlink_extra_admin_settings_submit in External Links Extra 8

Additional submit handler for the extlink_admin_settings form.

1 string reference to 'extlink_extra_admin_settings_submit'
extlink_extra_form_extlink_admin_settings_alter in ./extlink_extra.module
Implements hook_form_FORM_ID_alter() for extlink_admin_settings.

File

./extlink_extra.module, line 416

Code

function extlink_extra_admin_settings_submit(&$form, FormStateInterface $form_state) {

  // Fetch the submitted values.
  $values = $form_state
    ->getValues();

  // Store the values related to this module in config.
  \Drupal::configFactory()
    ->getEditable('extlink_extra.settings')
    ->set('extlink_page_title', $values['extlink_page_title'])
    ->set('extlink_alert_text', $values['extlink_alert_text'])
    ->set('extlink_alert_type', $values['extlink_alert_type'])
    ->set('extlink_modal_width', $values['extlink_modal_width'])
    ->set('extlink_alert_timer', $values['extlink_alert_timer'])
    ->set('extlink_cache_fix', $values['extlink_cache_fix'])
    ->set('extlink_508_fix', $values['extlink_508_fix'])
    ->set('extlink_508_text', $values['extlink_508_text'])
    ->set('extlink_url_override', $values['extlink_url_override'])
    ->set('extlink_exclude_warning', $values['extlink_exclude_warning'])
    ->save();
}