How to implement a hook in your module
Submitted by valerio on Fri, 06/19/2009 - 20:44
Hooks allow Drupal to be a modular system; in OO parlance they implement interface abstraction.
To implement hooks in your module you place module_invoke_all('$hook_nnme, $parameters) statements where you want the hook.to take place.
For a good example look at the node_import module. Open the file hook_node_import_docs.php and then look for the module_invoke_all statements in node_import.inc
- Login to post comments