1 node.module node_hook($node, $hook)

Determines whether a node hook exists.


Node|string $node: A node entity or a string containing the node type.

$hook: A string containing the name of the hook.

Return value

TRUE if the $hook exists in the node type of $node.:


core/modules/node/node.module, line 826
The core module that allows content to be submitted to the site.


function node_hook($node, $hook) {
  $base = node_type_get_base($node);
  return module_hook($base, $hook);