summaryrefslogtreecommitdiff
path: root/modules/search
diff options
context:
space:
mode:
Diffstat (limited to 'modules/search')
-rw-r--r--modules/search/search.module10
1 files changed, 7 insertions, 3 deletions
diff --git a/modules/search/search.module b/modules/search/search.module
index 2ab3a4210..2138562a6 100644
--- a/modules/search/search.module
+++ b/modules/search/search.module
@@ -98,6 +98,13 @@ function search_help($path, $arg) {
}
/**
+ * Implements hook_init().
+ */
+function search_init() {
+ drupal_add_css(drupal_get_path('module', 'search') . '/search.css', array('preprocess' => TRUE));
+}
+
+/**
* Implements hook_theme().
*/
function search_theme() {
@@ -875,9 +882,6 @@ function search_get_keys() {
* An HTML string containing the search form.
*/
function search_form($form, &$form_state, $action = '', $keys = '', $type = NULL, $prompt = NULL) {
- // Add CSS
- drupal_add_css(drupal_get_path('module', 'search') . '/search.css', array('preprocess' => FALSE));
-
if (!$action) {
$action = 'search/' . $type;
}