You are here

function apachesolr_index_action_form_reset_submit in Apache Solr Search 6.3

Same name and namespace in other branches
  1. 8 apachesolr.admin.inc \apachesolr_index_action_form_reset_submit()
  2. 7 apachesolr.admin.inc \apachesolr_index_action_form_reset_submit()

Submit handler for the Indexer actions form, delete button.

1 string reference to 'apachesolr_index_action_form_reset_submit'
apachesolr_index_action_form in ./apachesolr.admin.inc
Form builder for the Apachesolr Indexer actions form.

File

./apachesolr.admin.inc, line 894
Administrative pages for the Apache Solr framework.

Code

function apachesolr_index_action_form_reset_submit($form, &$form_state) {
  $destination = array();
  if (isset($_GET['destination'])) {
    $destination = drupal_get_destination();
    unset($_GET['destination']);
  }
  $env_id = $form_state['values']['env_id'];

  // $form_state['storage'] must be unset for redirection to occur. Otherwise
  // $form_state['rebuild'] is automatically set and this form will be
  // rebuilt.
  unset($form_state['storage']);
  $form_state['redirect'] = array(
    'admin/settings/apachesolr/settings/' . $env_id . '/index/reset',
    array(
      'query' => $destination,
    ),
  );
}