You are here

function shorten_cs_delete in Shorten URLs 6

Same name and namespace in other branches
  1. 7.2 shorten_cs.admin.inc \shorten_cs_delete()
  2. 7 shorten_cs.admin.inc \shorten_cs_delete()

Builds the form to delete a custom service.

1 string reference to 'shorten_cs_delete'
shorten_cs_menu in ./shorten_cs.module
Implementation of hook_menu().

File

./shorten_cs.admin.inc, line 188
Provides the configuration page for Shorten URLs Custom Services.

Code

function shorten_cs_delete($form_state, $service) {
  $form = array();
  $form['service'] = array(
    '#type' => 'value',
    '#value' => $service->name,
  );
  $form['#submit'] = array(
    'shorten_cs_delete_submit',
  );
  $form['#redirect'] = 'admin/settings/shorten/custom';
  return confirm_form($form, t('Are you sure you want to delete the custom service %service?', array(
    '%service' => $service->name,
  )), 'admin/settings/shorten/custom');
}