forked from bcit-ci/CodeIgniter
-
Notifications
You must be signed in to change notification settings - Fork 0
MailChimp API v1.3 Library
Derek Jones edited this page Jul 5, 2012
·
4 revisions
CodeIgniter Library for MailChimp API v1.3 MailChimp API v1.3 The CodeIgniter Way
Note:
This requires that you have an account with MailChimp, and are able to obtain your API Key:
Installation:
- Download and extract
- Place MCAPI.php in the /application/libraries/ folder of your CodeIgniter project
To use:
-
First, to load the library:
$config = array( 'apikey' => '' // Insert your api key 'secure' => FALSE // Optional (defaults to FALSE) ); $this->load->library('MCAPI', $config, 'mail_chimp');
Then, to use:
if($this->mail_chimp->listSubscribe($list_id, $email)) {
// $email is now subscribed to list with id: $list_id
}
Call all other methods in this manner. See full documentation on the MailChimp API.