You are here

function services_keyauth_admin_keys_delete_confirm in Services 6.2

Same name and namespace in other branches
  1. 7 auth/services_keyauth/services_keyauth.admin.inc \services_keyauth_admin_keys_delete_confirm()

Show a form to confirm whether an API key should be deleted.

1 string reference to 'services_keyauth_admin_keys_delete_confirm'
services_keyauth_menu in auth/services_keyauth/services_keyauth.module
Implementation of hook_menu().

File

auth/services_keyauth/services_keyauth.admin.inc, line 182
Generate security keys.

Code

function services_keyauth_admin_keys_delete_confirm(&$form_state, $kid = 0) {
  $key = db_fetch_object(db_query("SELECT * FROM {services_keys} WHERE kid = '%s'", $kid));
  $form['kid'] = array(
    '#type' => 'value',
    '#value' => $key->kid,
  );
  $message = t('Are you sure you want to delete the key %key?', array(
    '%key' => $key->kid,
  ));
  $caption = '';
  $caption .= '<p>' . t('This action cannot be undone.') . '</p>';
  return confirm_form($form, $message, 'admin/build/services/keys', $caption, t('Delete'));
}