function node_invoke in Drupal 4
Same name and namespace in other branches
- 5 modules/node/node.module \node_invoke()
- 6 modules/node/node.module \node_invoke()
- 7 modules/node/node.module \node_invoke()
Invoke a node hook.
Parameters
&$node: Either a node object, node array, or a string containing the node type.
$hook: A string containing the name of the hook.
$a2, $a3, $a4: Arguments to pass on to the hook, after the $node argument.
Return value
The returned value of the invoked hook.
12 calls to node_invoke()
- book_node_visitor_html_pre in modules/
book.module - Generates printer-friendly HTML for a node. This function is a 'pre-node' visitor function for book_recurse().
- node_delete in modules/
node.module - Delete a node.
- node_feed in modules/
node.module - A generic function for generating RSS feeds from a set of nodes.
- node_form_array in modules/
node.module - Generate the node editing form array.
- node_load in modules/
node.module - Load a node object from the database.
File
- modules/
node.module, line 308 - The core that allows content to be submitted to the site.
Code
function node_invoke(&$node, $hook, $a2 = NULL, $a3 = NULL, $a4 = NULL) {
if (node_hook($node, $hook)) {
$function = node_get_base($node) . "_{$hook}";
return $function($node, $a2, $a3, $a4);
}
}