function simplenews_subscription_list_remove in Simplenews 6.2
Same name and namespace in other branches
- 6 simplenews.admin.inc \simplenews_subscription_list_remove()
- 7.2 includes/simplenews.admin.inc \simplenews_subscription_list_remove()
- 7 includes/simplenews.admin.inc \simplenews_subscription_list_remove()
Menu callback: Mass subscribe to newsletters.
@todo Add 32char description field as unsubscription source
See also
simplenews_subscription_list_remove_submit()
1 string reference to 'simplenews_subscription_list_remove'
- simplenews_menu in ./
simplenews.module - Implementation of hook_menu().
File
- includes/
simplenews.admin.inc, line 661 - Newsletter admin, subscription admin, simplenews settings
Code
function simplenews_subscription_list_remove() {
$form['emails'] = array(
'#type' => 'textarea',
'#title' => t('Email addresses'),
'#cols' => 60,
'#rows' => 5,
'#description' => t('Email addresses must be separated by comma, space or newline.'),
);
$newsletters = array();
foreach (simplenews_get_newsletters(variable_get('simplenews_vid', ''), TRUE) as $newsletter) {
$newsletters[$newsletter->tid] = check_plain($newsletter->name);
}
$form['newsletters'] = array(
'#type' => 'checkboxes',
'#title' => t('Unsubscribe from'),
'#options' => $newsletters,
'#required' => TRUE,
);
$form['submit'] = array(
'#type' => 'submit',
'#value' => t('Unsubscribe'),
);
return $form;
}