Function __global->basic_newsletter_join

Definitions

sources/newsletter2.php

  • Add to the newsletter, in the simplest way.No authorisation support here, checks it works only for non-subscribed or non-confirmed members.
  • Visibility: public
  • Is abstract?: No
  • Is static?: No
  • Is final?: No
  • Returns: string

Parameters

Name Type Passed by reference? Variadic? Default Set Range Description
$email EMAIL No No required parameter N/A N/A The e-mail address of the subscriber
$language ?LANGUAGE_NAME No No Null N/A N/A The language (null: users)
$get_confirm_mail boolean No No False N/A N/A Whether to require a confirmation mail
$newsletter_id ?AUTO_LINK No No Null N/A N/A The newsletter to join (null: the first)
$forename string No No Blank (empty string) N/A N/A Subscribers forename
$surname string No No Blank (empty string) N/A N/A Subscribers surname

Returns

  • Newsletter password
  • Type: string
  • Set: N/A
  • Range: N/A

Preview

Code (PHP)

/**
 * Add to the newsletter, in the simplest way.No authorisation support here, checks it works only for non-subscribed or non-confirmed members.
 *
 * @param  EMAIL $email The e-mail address of the subscriber
 * @param  ?LANGUAGE_NAME $language The language (null: users)
 * @param  boolean $get_confirm_mail Whether to require a confirmation mail
 * @param  ?AUTO_LINK $newsletter_id The newsletter to join (null: the first)
 * @param  string $forename Subscribers forename
 * @param  string $surname Subscribers surname
 * @return string Newsletter password
 */

function basic_newsletter_join(string $email, ?string $language = null, bool $get_confirm_mail = false, ?int $newsletter_id = null, string $forename = '', string $surname = '') : string