Develop your own MailBeez

Published


Technically MailBeez is a framework for developing Trigger Email Campaigns.

A new MailBeez module can be developed very quickly. You only need to focus on building the Trigger Query Loop. MailBeez is taking care of putting together the email with using a template and a content file, sending the email out. Each email is tracked so it won’t be sent twice.

Let me take you very quickly through the concept – it is probably most easy for you to start from an existing MailBeez Module.

Build your Trigger Query

The following example shows how the receipients for a Birthday Greeting are selected.
An remember:each receipient will receive exactly 1 email per year

class birthday extends mailbeez {
// (…) some settings here
function getAudience() {
  $query_raw = "select c.customers_firstname, c.customers_lastname,
  c.customers_id, c.customers_email_address, c.customers_dob,
  date_format(c.customers_dob, '%d.%m.') as date_of_birth
  from " . TABLE_CUSTOMERS . " c
  where date_format(c.customers_dob,'%m%d') <

class birthday extends mailbeez {
// (…) some settings here
function getAudience() {
  $query_raw = "select c.customers_firstname, c.customers_lastname,
  c.customers_id, c.customers_email_address, c.customers_dob,
  date_format(c.customers_dob, '%d.%m.') as date_of_birth
  from " . TABLE_CUSTOMERS . " c
  where date_format(c.customers_dob,'%m%d') <

class birthday extends mailbeez {
// (…) some settings here
function getAudience() {
  $query_raw = "select c.customers_firstname, c.customers_lastname,
  c.customers_id, c.customers_email_address, c.customers_dob,
  date_format(c.customers_dob, '%d.%m.') as date_of_birth
  from " . TABLE_CUSTOMERS . " c
  where date_format(c.customers_dob,'%m%d') <

of course you can build whatever your want to fill the audience-array!

No restrictions: since MailBeez Modules are running in the catalog environment, you can include any functionality from you shop front-end.

Build the Email Template

Following the html-code in the file body_html.tpl




Using the common HTML Email template located in mailhive/common/templates the email will look like this:

Birthday Email

of course when sending the content will be personalized for the receipiente using the data you filled in to the array.

Imagine…

…how fast you can build Automatic Trigger Email Campaigns. Season Greetings, Holiday Greetings – you might give a Discount Coupon – can build within minutes! You can focus on building the Trigger Query and your are done.

EN

Get Started