1 filter.admin.inc filter_admin_format_filter_settings_form_redirect($form, &$form_state)

Submit handler for filter "Configure" buttons in filter_admin_format_form().

File

core/modules/filter/filter.admin.inc, line 456
Admin page callbacks for the Filter module.

Code

function filter_admin_format_filter_settings_form_redirect($form, &$form_state) {
  $trigger = $form_state['triggering_element'];
  $name = $trigger['#name'];

  // Save any changes to the allowed HTML values made by the front-end.
  if (isset($form_state['format']->filters['filter_html'])) {
    $form_state['format']->filters['filter_html']->settings['allowed_html'] = $form_state['values']['allowed_html'];
  }

  // Populate a format name if creating a new format.
  if (empty($form_state['format']->format)) {
    $form_state['format']->format = $form_state['values']['format'];
  }
  $form_state['redirect'] = 'admin/config/content/formats/' . $form_state['format']->format . '/filter-settings/' . $name;
}