| Versionen | |
|---|---|
| drupal6 – drupal7 | contact_admin_delete_submit($form, &$form_state) |
Process category delete form submission.
modules/
<?php
function contact_admin_delete_submit($form, &$form_state) {
$contact = $form_state['values']['contact'];
db_query("DELETE FROM {contact} WHERE cid = %d", $contact['cid']);
drupal_set_message(t('Category %category has been deleted.', array('%category' => $contact['category'])));
watchdog('mail', 'Contact form: category %category deleted.', array('%category' => $contact['category']), WATCHDOG_NOTICE);
$form_state['redirect'] = 'admin/build/contact';
return;
}
?>
Kommentare
Kommentar hinzufügen