You are here

function ife_form_id_delete_form_submit in Inline Form Errors 7

Same name and namespace in other branches
  1. 6.2 ife.settings.inc \ife_form_id_delete_form_submit()
  2. 6 ife.settings.inc \ife_form_id_delete_form_submit()
  3. 7.2 ife.settings.inc \ife_form_id_delete_form_submit()

Submit for confirm delete form for IFE form_ids

File

./ife.settings.inc, line 180
Admin settings pages

Code

function ife_form_id_delete_form_submit($form, &$form_state) {
  $form_id = $form_state['values']['fid'];

  // TODO Please review the conversion of this statement to the D7 database API syntax.

  /* db_query("DELETE FROM {ife} WHERE form_id = '%s'", $form_id) */
  db_delete('ife')
    ->condition('form_id', $form_id)
    ->execute();
  drupal_set_message(t('The form %form_id has been deleted.', array(
    '%form_id' => $form_id,
  )));
  cache_clear_all('ife_form_ids', 'cache');
  drupal_goto('admin/config/user-interface/ife');
}