function feedback_settings_delete in Feedback 5
Deletes a feedback page, if the user confirms
1 call to feedback_settings_delete()
- feedback_settings_page in ./
feedback.module - feedback admin center
File
- ./
feedback.module, line 234 - Enables a site-wide feedback page.
Code
function feedback_settings_delete($pagename) {
if ($_POST['op'] == t('Delete')) {
db_query("DELETE FROM {feedback_pages} WHERE name ='%s'", $pagename);
drupal_set_message(t('The feedback page has been deleted.'));
drupal_goto('admin/settings/feedback');
}
else {
$message = t('Are you sure you want to delete the feedback page "!page"?', array(
'!page' => $pagename,
));
$output = drupal_get_form('confirm_form', array(), $message, 'admin/settings/feedback', $message, t('Delete'), t('Cancel'));
return $output;
}
}