views:

259

answers:

1

I can't for the life of me figure out where the hook_search function in drupal is located. Is it something I need to add to a file to access?

+3  A: 

Hook functions don't exist by name -- they indicate a naming convention that can be followed to respond to that particular "hook"...

An example would be the node_search() function. When the search module calls module_invoke_all('search'), all functions named _foo__search(), where foo is the name of an enabled module, will be called. The details of the search hook in particular are found on api.drupal.org.

Eaton