No edit summary
No edit summary
Line 8: Line 8:


<syntaxhighlight lang="php">
<syntaxhighlight lang="php">
HTML = 1; // Let subscriber receive email in HTML format
// Let subscriber receive email in HTML format
HTML = 1;


PHP_LIST_URL = 'Full url to where you have installed PHPList e.g. https://example.com/list';
// Full url to where you have installed PHPList e.g. https://example.com/list
PHP_LIST_URL = '';


FIELD_EMAIL = 'email'; // Name of the form field holding the email of the subscriber
// Name of the form field holding the email of the subscriber
FIELD_EMAIL = 'email';


FIELD_NAME = 'name'; // Name of the form field holding the name of the subscriber
// Name of the form field holding the name of the subscriber
FIELD_NAME = 'name';


FIELD_AS_EMAIL = 'useFieldAsEmail'; // Name of a form field where its value holds the name of another form field holding the email of the subscriber
// Name of a form field where its value holds the name of another form field holding the email of the subscriber
FIELD_AS_EMAIL = 'useFieldAsEmail';


FIELD_AS_NAME = 'useFieldAsName'; // Name of a form field where its value holds the name of another form field holding the name of the subscriber
// Name of a form field where its value holds the name of another form field holding the name of the subscriber
FIELD_AS_NAME = 'useFieldAsName';


// If the form holds no information on what list to subscribe to, the subscribe the user to the following lists by default.
// If the form holds no information on what list to subscribe to, the subscribe the user to the following lists by default.

Revision as of 21:21, 30 March 2023

Extension name : phpList

Allows for subscribing a user to your instalment of PHPList. ( https://www.phplist.org )

PHPList needs a name and an email address as a bare minimum, so a form should provide that information.

All the other configuration settings can be done inside the PostHandler PHP file. ( FlexForm/src/Modules/Handlers/phpList/PostHandler.php )

// Let subscriber receive email in HTML format
HTML = 1;

// Full url to where you have installed PHPList e.g. https://example.com/list
PHP_LIST_URL = '';

// Name of the form field holding the email of the subscriber
FIELD_EMAIL = 'email';

// Name of the form field holding the name of the subscriber
FIELD_NAME = 'name'; 

// Name of a form field where its value holds the name of another form field holding the email of the subscriber
FIELD_AS_EMAIL = 'useFieldAsEmail'; 

// Name of a form field where its value holds the name of another form field holding the name of the subscriber
FIELD_AS_NAME = 'useFieldAsName'; 

// If the form holds no information on what list to subscribe to, the subscribe the user to the following lists by default.
DEFAULT_LISTS = [

   3 => 'signup',

   4 => 'signup',

   5 => 'signup',

   6 => 'signup',

   7 => 'signup',

   8 => 'signup'

];