dev-master
9999999-devSimple Craft plugin for subscribing to a Mailjet list.
The Requires
cms mailjet craftcms craft-plugin craft
Simple Craft plugin for subscribing to a Mailjet list.
Simple Craft plugin for subscribing to a Mailjet list., (*1)
This plugin requires Craft CMS 3.0.0 or later., (*2)
In the plugin settings you have to set - Public API key - Private API key - List ID you want to use (currently you have to use the same list in all forms), (*3)
The plugin consists of a controller function that needs an email address, which it then passes on to the mailjet service to handle subscribing.
Post your subscription form to mailjet-subscribe/list/subscribe
like the example below:, (*4)
<form class="form" method="POST"> {{ csrfInput() }} <input type="hidden" name="action" value="mailjet-subscribe/list/subscribe"> <input type="email" id="email" name="email" required value="{% if (mailjetSubscribe is defined) and (not mailjetSubscribe.success) %}{{ mailjetSubscribe.values.email }}{% endif %}"> <input type="submit" value="Subscribe"> </form>
Simple Craft plugin for subscribing to a Mailjet list.
cms mailjet craftcms craft-plugin craft