function simplenews_confirm_add_form in Simplenews 6
Same name and namespace in other branches
- 5 simplenews.module \simplenews_confirm_add_form()
- 6.2 includes/simplenews.subscription.inc \simplenews_confirm_add_form()
- 7.2 includes/simplenews.subscription.inc \simplenews_confirm_add_form()
- 7 includes/simplenews.subscription.inc \simplenews_confirm_add_form()
Generate the confirm subscription form.
See also
simplenews_confirm_add_form_submit()
1 string reference to 'simplenews_confirm_add_form'
- simplenews_confirm_subscription in ./
simplenews.subscription.inc - Menu callback: confirm the user's (un)subscription request
File
- ./
simplenews.subscription.inc, line 153 - (Un)subscription and (un)subscription confirmation
Code
function simplenews_confirm_add_form(&$form_state, $mail, $newsletter) {
$form = array();
$form['question'] = array(
'#value' => '<p>' . t('Are you sure you want to add %user to the %newsletter mailing list?', array(
'%user' => simplenews_mask_mail($mail),
'%newsletter' => $newsletter->name,
)) . "<p>\n",
);
$form['mail'] = array(
'#type' => 'value',
'#value' => $mail,
);
$form['newsletter'] = array(
'#type' => 'value',
'#value' => $newsletter,
);
$form['#redirect'] = '';
return confirm_form($form, t('Confirm subscription'), '', t('You always have the option of unsubscribing later.'), t('Subscribe'), t('Cancel'));
}