function search_form_submit

Same name and namespace in other branches
  1. 6.x drupal-6.x/modules/search/search.pages.inc \search_form_submit()

Process a search form submission.

Archivo

drupal-7.x/modules/search/search.pages.inc, line 150
User page callbacks for the search module.

Código

function search_form_submit($form, &$form_state) {
  $keys = $form_state['values']['processed_keys'];
  if ($keys == '') {
    form_set_error('keys', t('Please enter some keywords.'));
    // Fall through to the form redirect.
  }

  $form_state['redirect'] = $form_state['action'] . '/' . $keys;
}