Form submission handler.
array $form: An associative array containing the structure of the form.
array $form_state: An associative array containing the current state of the form.
Overrides FormInterface::submitForm
public function submitForm(array &$form, array &$form_state) {
$ip = trim($form_state['values']['ip']);
$this->ipManager
->banIp($ip);
drupal_set_message(t('The IP address %ip has been banned.', array(
'%ip' => $ip,
)));
$form_state['redirect'] = 'admin/config/people/ban';
}