function feeds_tamper_ui_delete_form in Feeds Tamper 7
Same name and namespace in other branches
- 6 feeds_tamper_ui/feeds_tamper_ui.admin.inc \feeds_tamper_ui_delete_form()
Delete plugin form.
1 string reference to 'feeds_tamper_ui_delete_form'
- feeds_tamper_ui_menu in feeds_tamper_ui/
feeds_tamper_ui.module - Implements hook_menu().
File
- feeds_tamper_ui/
feeds_tamper_ui.admin.inc, line 492 - Forms and their accompanying validation and submit functions for Feeds Tamper UI.
Code
function feeds_tamper_ui_delete_form($form, &$form_state, $instance) {
if (!$instance) {
drupal_set_message(t('Invalid plugin id.'), 'error');
return;
}
$form_state['instance'] = $instance;
if ($instance->export_type & EXPORT_IN_CODE) {
$question = t('Would you really like to revert the plugin @instance?', array(
'@instance' => $instance->description,
));
$button_label = t('Revert');
}
else {
$question = t('Would you really like to delete the plugin @instance?', array(
'@instance' => $instance->description,
));
$button_label = t('Delete');
}
return confirm_form($form, $question, 'admin/structure/feeds/' . $instance->importer . '/tamper', NULL, $button_label);
}