function node_delete_multiple

cis7 node.module node_delete_multiple($nids)
cle7 node.module node_delete_multiple($nids)
elmsmedia7 node.module node_delete_multiple($nids)
icor7 node.module node_delete_multiple($nids)
meedjum_blog7 node.module node_delete_multiple($nids)
mooc7 node.module node_delete_multiple($nids)

Deletes multiple nodes.


$nids: An array of node IDs.

5 calls to node_delete_multiple()
devel_generate_content_kill in sites/all/modules/ulmus/devel/devel_generate/
Handle the devel_generate_content_form request to kill all of the content. This is used by both the batch and non-batch branches of the code.
FeedsNodeProcessor::entityDeleteMultiple in sites/all/modules/ulmus/feeds/plugins/
Delete a series of nodes.
node_delete in modules/node/node.module
Deletes a node.
node_multiple_delete_confirm_submit in modules/node/
Form submission handler for node_multiple_delete_confirm().
node_user_delete in modules/node/node.module
Implements hook_user_delete().


modules/node/node.module, line 1243
The core that allows content to be submitted to the site. Modules and scripts may programmatically submit nodes using the usual form API pattern.


function node_delete_multiple($nids) {
  $transaction = db_transaction();
  if (!empty($nids)) {
    $nodes = node_load_multiple($nids, array());

    try {
      foreach ($nodes as $nid => $node) {
        // Call the node-specific callback (if any):
        node_invoke($node, 'delete');
        module_invoke_all('node_delete', $node);
        module_invoke_all('entity_delete', $node, 'node');
        field_attach_delete('node', $node);

        // Remove this node from the search index if needed.
        // This code is implemented in node module rather than in search module,
        // because node module is implementing search module's API, not the other
        // way around.
        if (module_exists('search')) {
          search_reindex($nid, 'node');

      // Delete after calling hooks so that they can query node tables as needed.
      db_delete('node')->condition('nid', $nids, 'IN')->execute();
      db_delete('node_revision')->condition('nid', $nids, 'IN')->execute();
      db_delete('history')->condition('nid', $nids, 'IN')->execute();
      db_delete('node_access')->condition('nid', $nids, 'IN')->execute();
    catch (Exception $e) {
      watchdog_exception('node', $e);
      throw $e;

    // Clear the page and block and node_load_multiple caches.



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.