function hook_node_prepare

×

Error message

User warning: The following module is missing from the file system: theme/theme. For information about how to fix this, see the documentation page. in _drupal_trigger_error_with_delayed_logging() (line 1156 of /var/www/html/elmsln_community/api.elmsln.org/includes/bootstrap.inc).
cis7 node.api.php hook_node_prepare($node)
cle7 node.api.php hook_node_prepare($node)
elmsmedia7 node.api.php hook_node_prepare($node)
icor7 node.api.php hook_node_prepare($node)
meedjum_blog7 node.api.php hook_node_prepare($node)
mooc7 node.api.php hook_node_prepare($node)

Act on a node object about to be shown on the add/edit form.

This hook is invoked from node_object_prepare() after the type-specific hook_prepare() is invoked.

Parameters

$node: The node that is about to be shown on the add/edit form.

Related topics

5 functions implement hook_node_prepare()

Note: this list is generated by pattern matching, so it may include some functions that are not actually implementations of this hook.

book_node_prepare in modules/book/book.module
Implements hook_node_prepare().
comment_node_prepare in modules/comment/comment.module
Implements hook_node_prepare().
menu_node_prepare in modules/menu/menu.module
Implements hook_node_prepare().
rubric_node_prepare in sites/all/modules/elmsln_contrib/rubric/rubric.module
Implements hook_node_prepare().
translation_node_prepare in modules/translation/translation.module
Implements hook_node_prepare().
2 invocations of hook_node_prepare()
node_object_prepare in modules/node/node.module
Prepares a node object for editing.
node_object_prepare in modules/node/node.module
Prepares a node object for editing.

File

modules/node/node.api.php, line 642
Hooks provided by the Node module.

Code

function hook_node_prepare($node) {
  if (!isset($node->comment)) {
    $node->comment = variable_get("comment_$node->type", COMMENT_NODE_OPEN);
  }
}
Error | ELMSLN API

Error

×

Error message

  • Warning: Cannot modify header information - headers already sent by (output started at /var/www/html/elmsln_community/api.elmsln.org/includes/common.inc:2791) in drupal_send_headers() (line 1499 of /var/www/html/elmsln_community/api.elmsln.org/includes/bootstrap.inc).
  • Error: Call to undefined function apc_delete() in DrupalAPCCache->clear() (line 289 of /var/www/html/elmsln_community/api.elmsln.org/sites/all/modules/apc/drupal_apc_cache.inc).
The website encountered an unexpected error. Please try again later.