Documentation

PA_NewsletterType
in package

The PuzzleAnywhere NewsletterType class. It allows for retrieving newsletter type data.

Table of Contents

$description  : string
The newsletter type description.
$id  : int
The `NewsletterType` ID.
$name  : string
The name of the newsletter type.
$requires_subscription  : bool
Denotes whether the newsletter type requires a subscription to access.
$subscribed  : bool
Denotes whether the newsletter type requires a subscription.
get()  : PA_NewsletterType
Retrieves a newsletter type record.
get_all()  : array<string|int, PA_NewsletterType>
Retrieves all available newsletter type record.
get_all_available_by_token()  : array<string|int, PA_NewsletterType>
Retrieve all available newsletter types by token.
get_by_token()  : array<string|int, PA_NewsletterType>
Retrieve newsletter types by token.
unsubscribe_from_all_by_token()  : null
Unsubscribe from all newsletter types by token.
update_by_token()  : null
Update newsletter type subscriptions by token.

Properties

Methods

unsubscribe_from_all_by_token()

Unsubscribe from all newsletter types by token.

public static unsubscribe_from_all_by_token(string $token) : null
Parameters
$token : string

The subscription token.

Return values
null

update_by_token()

Update newsletter type subscriptions by token.

public static update_by_token(string $token[, mixed $newsletter_types = [] ][, mixed $email_offers = false ]) : null
Parameters
$token : string

The newsletter types token

$newsletter_types : mixed = []
$email_offers : mixed = false
Tags
params

int[] $newsletter_types An array of newsletter type IDs.

params

boolean $email_offers Denotes whether email offers should be enabled for the newsletter type.

Return values
null

Search results