node_delete_confirm

5 node.module node_delete_confirm($node)
6 node.pages.inc node_delete_confirm(&$form_state, $node)
7 node.pages.inc node_delete_confirm($form, &$form_state, $node)
8 node.pages.inc node_delete_confirm($form, &$form_state, $node)

Menu callback -- ask for confirmation of node deletion

1 string reference to 'node_delete_confirm'

File

modules/node/node.pages.inc, line 470
Page callbacks for adding, editing, deleting, and revisions management for content.

Code

function node_delete_confirm($form, &$form_state, $node) {
  $form['#node'] = $node;
  // Always provide entity id in the same form key as in the entity edit form.
  $form['nid'] = array(
    '#type' => 'value',
    '#value' => $node->nid,
  );
  return confirm_form($form, 
    t('Are you sure you want to delete %title?', array('%title' => $node->title)), 
    'node/' . $node->nid, 
    t('This action cannot be undone.'), 
    t('Delete'), 
    t('Cancel')
  );
}
Login or register to post comments