function user_edit_cancel_submit
user_edit_cancel_submit($form, &$form_state)
Submit function for the 'Cancel account' button on the user edit form.
File
- modules/user/user.pages.inc, line 377
- User page callback file for the user module.
Code
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)); }
© 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!user!user.pages.inc/function/user_edit_cancel_submit/7.x