function flag_delete_confirm in Flag 6
Same name and namespace in other branches
- 5 includes/flag.admin.inc \flag_delete_confirm()
- 6.2 includes/flag.admin.inc \flag_delete_confirm()
- 7.3 includes/flag.admin.inc \flag_delete_confirm()
- 7.2 includes/flag.admin.inc \flag_delete_confirm()
Delete flag page.
1 string reference to 'flag_delete_confirm'
- flag_menu in ./
flag.module - Implementation of hook_menu().
File
- includes/
flag.admin.inc, line 402 - Contains administrative pages for creating, editing, and deleting flags.
Code
function flag_delete_confirm(&$form_state, $name) {
$flag = flag_get_flag($name);
if (empty($flag)) {
drupal_goto('admin/build/flags');
}
$form['fid'] = array(
'#type' => 'value',
'#value' => $flag->fid,
);
return confirm_form($form, t('Are you sure you want to delete %title?', array(
'%title' => $flag
->get_title(),
)), !empty($_GET['destination']) ? $_GET['destination'] : 'admin/build/flags', isset($flag->module) ? t('This flag is provided by the @module module. It will loose any customizations and be disabled.', array(
'@module' => node_get_types('name', $flag->module),
)) : t('This action cannot be undone.'), t('Delete'), t('Cancel'));
}