function simplenews_subscription_list_remove in Simplenews 7
Same name and namespace in other branches
- 6.2 includes/simplenews.admin.inc \simplenews_subscription_list_remove()
- 6 simplenews.admin.inc \simplenews_subscription_list_remove()
- 7.2 includes/simplenews.admin.inc \simplenews_subscription_list_remove()
Menu callback: Mass subscribe to newsletters.
@todo Add 32char description field as unsubsription source
See also
simplenews_subscription_list_remove_submit()
1 string reference to 'simplenews_subscription_list_remove'
- simplenews_menu in ./
simplenews.module - Implements hook_menu().
File
- includes/
simplenews.admin.inc, line 972 - Newsletter admin, subscription admin, simplenews settings
Code
function simplenews_subscription_list_remove($form, &$form_state) {
$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.'),
);
$form['newsletters'] = array(
'#type' => 'fieldset',
'#description' => t('Unsubscribe from'),
'#tree' => TRUE,
);
foreach (simplenews_categories_load_multiple() as $category) {
$form['newsletters'][$category->tid] = array(
'#type' => 'checkbox',
'#title' => check_plain(_simplenews_newsletter_name($category)),
'#description' => _simplenews_newsletter_description($category),
);
}
$form['submit'] = array(
'#type' => 'submit',
'#value' => t('Unsubscribe'),
);
return $form;
}