node_form_delete_submit
function node_form_delete_submit
node_form_delete_submit($form, &$form_state)
Form submission handler for node_form().
Handles the 'Delete' button on the node form.
See also
File
- modules/node/node.pages.inc, line 338
- Page callbacks for adding, editing, deleting, and revisions management for content.
Code
function node_form_delete_submit($form, &$form_state) { $destination = array(); if (isset($_GET['destination'])) { $destination = drupal_get_destination(); unset($_GET['destination']); } $node = $form['#node']; $form_state['redirect'] = array('node/' . $node->nid . '/delete', array('query' => $destination)); }
© 2001–2016 by the original authors
Licensed under the GNU General Public License, version 2 and later.
Drupal is a registered trademark of Dries Buytaert.
https://api.drupal.org/api/drupal/modules!node!node.pages.inc/function/node_form_delete_submit/7.x