node_form_delete_submit
modules/node/node.pages.inc, строка 305
- Версии
- 6
node_form_delete_submit($form, &$form_state)
Button sumit function: handle the 'Delete'
button on the node form.
Код
<?php
function node_form_delete_submit($form, &$form_state) {
$destination = '';
if (isset($_REQUEST['destination'])) {
$destination = drupal_get_destination();
unset($_REQUEST['destination']);
}
$node = $form['#node'];
$form_state['redirect'] = array('node/'. $node->nid .'/delete', $destination);
}
?>
Войдите или зарегистрируйтесь, чтобы получить возможность отправлять комментарии