function values_delete_confirm in Values 6
Same name and namespace in other branches
- 7 values.module \values_delete_confirm()
Confirmation form to delete a value object from the database.
1 string reference to 'values_delete_confirm'
- values_menu in ./
values.module - Implementation of hook_menu().
File
- ./
values.module, line 399 - API for managing reusable value sets.
Code
function values_delete_confirm(&$form_state, $values) {
$form['name'] = array(
'#type' => 'value',
'#value' => $values->name,
);
$action = $values->export_type & EXPORT_IN_CODE ? 'revert' : 'delete';
$form['action'] = array(
'#type' => 'value',
'#value' => $action,
);
return confirm_form($form, t('Are you sure you want to !action !name?', array(
'!action' => $action,
'!name' => '<em>' . $values->description . '</em>',
)), 'admin/content/values', t('This action cannot be undone.'), t('!action', array(
'!action' => ucfirst($action),
)), t('Cancel'));
}