public function ForumSettingsForm::submitForm in Zircon Profile 8
Same name and namespace in other branches
- 8.0 core/modules/forum/src/ForumSettingsForm.php \Drupal\forum\ForumSettingsForm::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
- core/
modules/ forum/ src/ ForumSettingsForm.php, line 74 - Contains \Drupal\forum\ForumSettingsForm.
Class
- ForumSettingsForm
- Configure forum settings for this site.
Namespace
Drupal\forumCode
public function submitForm(array &$form, FormStateInterface $form_state) {
$this
->config('forum.settings')
->set('topics.hot_threshold', $form_state
->getValue('forum_hot_topic'))
->set('topics.page_limit', $form_state
->getValue('forum_per_page'))
->set('topics.order', $form_state
->getValue('forum_order'))
->save();
parent::submitForm($form, $form_state);
}