The validation function added to the search block doesn't exist. Furthermore, since search validation happens in the submit handlers (interesting, isn't it!), there is no need for a validation function for this form.
diff -u -p -r1.258 search.module
--- search/search.module 26 May 2008 17:22:59 -0000 1.258
+++ search/search.module 9 Jul 2008 11:33:26 -0000
@@ -1069,7 +1069,6 @@ function search_box(&$form_state, $form_
);
$form['submit'] = array('#type' => 'submit', '#value' => t('Search'));
$form['#submit'][] = 'search_box_form_submit';
- $form['#validate'][] = 'search_box_form_validate';
return $form;
}
Comments
Comment #1
dries commentedCommitted to CVS HEAD. Thanks.
Comment #2
robertdouglass commentedComment #3
douggreen commentedI confirm that the patch applies, and that it fixes a valid issue. I don't know if it's worth being committed, so I'm not marking it RTBC, without further discussion. Does having this in 6.x cause any problems?
Comment #4
c960657 commentedI think it deserves to be fixed. It may not be a big problem, but it does cause confusion for people reading the code, and the fix is trivial. The patch still applies.
Comment #5
gábor hojtsyCommitted to Drupal 6, thanks.