public function NegotiationSessionForm::submitForm

Implements \Drupal\Core\Form\FormInterface::submitForm().

Overrides SystemConfigFormBase::submitForm

File

drupal/core/modules/language/lib/Drupal/language/Form/NegotiationSessionForm.php, line 44
Contains \Drupal\language\Form\NegotiationSessionForm.

Class

NegotiationSessionForm
Configure the session language negotiation method for this site.

Namespace

Drupal\language\Form

Code

public function submitForm(array &$form, array &$form_state) {
  $this->configFactory
    ->get('language.settings')
    ->set('session.parameter', $form_state['values']['language_negotiation_session_param'])
    ->save();
  parent::submitForm($form, $form_state);
}