You are here

function subscriptions_delete_form_submit in Subscriptions 7

Same name and namespace in other branches
  1. 5.2 subscriptions.module \subscriptions_delete_form_submit()
  2. 6 subscriptions.module \subscriptions_delete_form_submit()
  3. 2.0.x subscriptions.module.old.php \subscriptions_delete_form_submit()

Deletes Subscription form submit handler.

_state

Parameters

array $form:

1 string reference to 'subscriptions_delete_form_submit'
subscriptions_delete_form in ./subscriptions.module
Provides the form definition for deleting subscriptions via s/del/... (aka subscriptions/rem/...) link.

File

./subscriptions.module, line 693
Subscriptions module.

Code

function subscriptions_delete_form_submit(array $form, array &$form_state) {
  $data = $form_state['values']['data'];
  subscriptions_delete($data['4'], $data['0'], $data['1'], $data['2'], $data['3']);
  drupal_set_message(t('Your subscription was deactivated.'));
  $form_state['redirect'] = '<front>';
}