function hook_entity_load


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/
cis7 system.api.php hook_entity_load($entities, $type)
cle7 system.api.php hook_entity_load($entities, $type)
elmsmedia7 system.api.php hook_entity_load($entities, $type)
icor7 system.api.php hook_entity_load($entities, $type)
meedjum_blog7 system.api.php hook_entity_load($entities, $type)
mooc7 system.api.php hook_entity_load($entities, $type)

Act on entities when loaded.

This is a generic load hook called for all entity types loaded via the entity API.


$entities: The entities keyed by entity ID.

$type: The type of entities being loaded (i.e. node, user, comment).

Related topics

2 functions implement hook_entity_load()

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

entity_crud_hook_test_entity_load in modules/simpletest/tests/entity_crud_hook_test.module
Implements hook_entity_load().
rdf_entity_load in modules/rdf/rdf.module
Implements hook_entity_load().
4 invocations of hook_entity_load()
DrupalDefaultEntityController::attachLoad in includes/
Attaches data to entities upon loading.
EntityAPIControllerExportable::attachLoad in sites/all/modules/ulmus/entity/includes/
field_attach_load in modules/field/
Loads fields for the current revisions of a group of entities.
node_preview in modules/node/
Generates a node preview.


modules/system/system.api.php, line 302
Hooks provided by Drupal core and the System module.


function hook_entity_load($entities, $type) {
  foreach ($entities as $entity) {
    $entity->foo = mymodule_add_something($entity, $type);



Error message

  • Warning: Cannot modify header information - headers already sent by (output started at /var/www/html/elmsln_community/ in drupal_send_headers() (line 1499 of /var/www/html/elmsln_community/
  • Error: Call to undefined function apc_delete() in DrupalAPCCache->clear() (line 289 of /var/www/html/elmsln_community/
The website encountered an unexpected error. Please try again later.