Mailchimp for FormIt

Package for subscribing users in Mailchimp lists using FormIt.

Creator: Sterc Online Agency (sterc)

Need help installing this extra?

About Mailchimp for FormIt

This extra adds subscribers to Mailchimp lists using FormIt and the Mailchimp API. It adds a snippet for retrieving Mailchimp lists in a single select TV and a FormIt hook for subscribing Mailchimp users to the list provided in the pages Template Variable.

Information

Released
January 4, 2022

Supported Database
MySQL

License
GPLv2

Supported Versions
2.0 - Current

Downloads
2,843

Instructions

Package for subscribing users in Mailchimp lists using FormIt.

Adds a snippet for retrieving Mailchimp lists in a single select TV and a

FormIt hook for subscribing Mailchimp users to the list provided in the pages Template Variable.

Functionalities

* FormIt hook for subscribing users to Mailchimp lists based on TV value

* MailChimpGetLists: Snippet for creating a select list of MailChimp lists.

How to get set up

* Add MailChimp API Key in systemsettings: mailchimpsubscribe.mailchimp_api_key

* Create a new single select TV variable and set the input option values to:

    @EVAL return $modx->runSnippet('MailChimpGetLists');

* Add MailChimp List ID TV in systemsettings: mailchimpsubscribe.list_tv

* Add MailChimpSubscribe to your FormIt hooks

* Add in your chunk the placeholder fi.error.mailchimp, which holds all MailChimp error messages.

* Add a field called newsgroup, if the value of this field is set to yes, the user will be subscribed to the mailchimp list.

Properties

* mailchimpListId: Mailchimp List ID.

* mailchimpFields: Configuration containing the field mapping between FormIt form and Mailchimp merge tags.

* mailchimpSubscribeField: Field name to use for subscribing users to mailchimp.

* mailchimpSubscribeFieldValue: Field value to use for subscribing users to mailchimp.

Example usage

`

&validationErrorMessage=`true`

&store=`1`

&submitVar=`newsletter-submit`

&mailchimpListId=`12345678abc`

&mailchimpFields=`name=FNAME,email=EMAIL`

&mailchimpSubscribeField=`newsletter`

&mailchimpSubscribeFieldValue=`1`

New in 1.2.4-pl

MailChimpSubscribe 1.2.4-pl

  • Added support for interests

MailChimpSubscribe 1.2.3-pl

  • Fix empty merge_fields bug (issue #1)
  • Add a log statement to ease debugging of errors (PR #2, thanks to Mark-H)

MailChimpSubscribe 1.2.2-pl

  • Prevent mailchimpsubscribe from stopping the form process unless mailchimpValidate property is set to true

MailChimpSubscribe 1.2.1-pl

  • Update README.md

MailChimpSubscribe 1.2.0-pl

  • Added option dynamic setting the subscription status to overwrite double opt-in.
  • Added options to add tags to subscription

Current releases

1.2.4-pl
View | Download
January 4, 2022
2.0 - Current

1.2.3-pl
View | Download
July 8, 2021
2.0 - Current

1.2.1-pl
View | Download
April 5, 2019
2.5 - Current

1.0.1-pl
View | Download
November 23, 2018
2.5 - <2.6