function password_policy_admin_delete in Password Policy 6
Same name and namespace in other branches
- 7 password_policy.admin.inc \password_policy_admin_delete()
Confirmation form for the deletion of a password policy. Deletion takes place in password_policy_admin_delete_submit().
1 string reference to 'password_policy_admin_delete'
- password_policy_menu in ./
password_policy.module - Implements hook_menu().
File
- ./
password_policy.admin.inc, line 360 - Admin page callback file for the password_policy module.
Code
function password_policy_admin_delete($form_state, $pid) {
if (is_numeric($pid) && ($policy = _password_policy_load_policy_by_pid($pid))) {
$form['pid'] = array(
'#type' => 'hidden',
'#value' => $policy['pid'],
);
return confirm_form($form, t('Are you sure you want to delete the policy %name?', array(
'%name' => $policy['name'],
)), 'admin/settings/password_policy/list', t('This action cannot be undone.'), t('Delete'), t('Cancel'));
}
else {
drupal_not_found();
exit;
}
}