user_edit_cancel_submit
- Versions
- 7
user_edit_cancel_submit($form, &$form_state)
Submit function for the 'Cancel account' button on the user edit form.
Code
modules/user/user.pages.inc, line 290
<?php
function user_edit_cancel_submit($form, &$form_state) {
$destination = array();
if (isset($_GET['destination'])) {
$destination = drupal_get_destination();
unset($_GET['destination']);
}
// Note: We redirect from user/uid/edit to user/uid/cancel to make the tabs disappear.
$form_state['redirect'] = array("user/" . $form['#user']->uid . "/cancel", array('query' => $destination));
}
?>Login or register to post comments 