search_form_submit

  1. drupal
    1. 5
    2. 8 search.pages.inc
    3. 6 search.pages.inc
    4. 7 search.pages.inc
Versions
5 search_form_submit($form_id, $form_values)
8 – 7 search_form_submit($form, &$form_state)

Process a search form submission.

Related topics

Code

modules/search/search.module, line 1022

<?php
function search_form_submit($form_id, $form_values) {
  $keys = $form_values['processed_keys'];
  if ($keys == '') {
    form_set_error('keys', t('Please enter some keywords.'));
    // Fall through to the drupal_goto() call.
  }

  $type = $form_values['module'] ? $form_values['module'] : 'node';
  return 'search/' . $type . '/' . $keys;
}
?>