You are here

function spamicide_delete_confirm_submit in Spamicide 6

Same name and namespace in other branches
  1. 5 spamicide.module \spamicide_delete_confirm_submit()
  2. 7 spamicide.module \spamicide_delete_confirm_submit()

submission handler of Spamicide delete confirm_form

File

./spamicide.module, line 283
This module provides yet another tool to eliminate spam.

Code

function spamicide_delete_confirm_submit($form, &$form_state) {
  $spamicide_form_id = $form_state['values']['spamicide_form_id'];
  $delete = $form_state['values']['spamicide_delete'];
  db_query("DELETE FROM {spamicide} WHERE form_id = '%s'", $spamicide_form_id);
  drupal_set_message(t('Deleted Spamicide for form %form_id.', array(
    '%form_id' => $spamicide_form_id,
  )));

  // redirect to Spamicide admin
  $form_state['redirect'] = 'admin/settings/spamicide';
}