truecastdesign/mailchimp
Composer 安装命令:
composer require truecastdesign/mailchimp
包简介
This library provides a simple MailChimp API v3 to signup people to a mailing list.
关键字:
README 文档
README
Version: v1.0.1
This library provides a simple MailChimp API v3 to signup people to a mailing list.
Install
To install with composer:
composer require truecastdesign/mailchimp
Requires PHP 7.1 or newer.
Usage
Here's a basic usage example:
Get your API key and list id from MailChimp
Status options are 'pending',
# composer autoloader require '/path/to/vendor/autoload.php'; $MailChimp = new \Truecast\MailChimp('kl32j4kl23jklj4l23j4kl23j34-us14'); $member = ['first_name'=>'John', 'last_name'=>'Doe', 'email'=>'johndoe@gmail.com']; try { $MailChimp->add($member, 'listid123456', 'pending'); # member array, list id, status # success # display a notice or take them somewhere } catch (\Exception $ex) { # failed trigger_error("We were not able to add you to our list. Error: ".$ex->getMessage(), 256); }
统计信息
- 总下载量: 5
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 1
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2020-07-16