function contact_category_delete_form_submit
Form submission handler for contact_category_delete_form().
File
-
modules/
contact/ contact.admin.inc, line 217
Code
function contact_category_delete_form_submit($form, &$form_state) {
$contact = $form['contact']['#value'];
db_delete('contact')->condition('cid', $contact['cid'])
->execute();
drupal_set_message(t('Category %category has been deleted.', array(
'%category' => $contact['category'],
)));
watchdog('contact', 'Category %category has been deleted.', array(
'%category' => $contact['category'],
), WATCHDOG_NOTICE);
$form_state['redirect'] = 'admin/structure/contact';
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.