You are here

function webform_validation_delete_rule in Webform Validation 7

Same name and namespace in other branches
  1. 6 webform_validation.admin.inc \webform_validation_delete_rule()

Confirmation form to delete a rule.

1 string reference to 'webform_validation_delete_rule'
webform_validation_menu in ./webform_validation.module
Implements hook_menu().

File

./webform_validation.admin.inc, line 363
Manages validation rules administration UI.

Code

function webform_validation_delete_rule($form, &$form_state, $rule) {
  if (isset($rule['ruleid'])) {
    $form['ruleid'] = array(
      '#type' => 'value',
      '#value' => $rule['ruleid'],
    );
  }
  return confirm_form($form, t('Are you sure you want to delete the rule %name?', array(
    '%name' => $rule['rulename'],
  )), 'node/' . $rule['nid'] . '/webform/validation', NULL, t('Delete'));
}