Personalizing E-mails


A powerful feature of MailList King is the ability to personalize outgoing messages with the name and other details of the recipient.  To take advantage of this feature you need only specify the personalization fields in your text of your message.  As the message is sent the fields are replaced with the appropriate value for each message recipient.

You can also insert custom text into your message depending on a database field of a member, e.g. so you can have a different offer for recipients in the USA, or say "Dear Sir" for men and "Dear Madam" for women.

MailList King supports the use of any database field for personalization (including any custom fields that you have created).

Here are some common personalization fields:

%FullName% Replaced with the Full Name of the member.  The Full Name field is filled automatically when retrieving e-mail addresses if the information is available
%FirstName% Replaced with the First Name of the member.  This field is filled when adding new address if you have specified the appropriate setting under Options
%LastName% Replaced with the Last Name of the member.  This field is filled when adding new address if you have specified the appropriate setting under Options
%Company% Replaced with the company field from your database
%Email% Replaced with the e-mail address of the user
%Field:MemberID% Replaced with the Member ID for the user.  You might use this to track clicked links in your messages
%Field:CustomFieldName% Specify any of your custom fields to include your own data in your message.  You can fill custom fields in the Edit Member dialog or when importing

 

To insert a personalization field

1. Select Home > New Email

2. On the message editing toolbar click the Personalization button and choose the field to insert

Note: If you have specified that each message has multiple recipients then will confirm changing this to single recipients (as each recipient will have a custom message).

 

Example

An example message might look like this:

Dear %FirstName%,

It is now %Date%, so isn't it time you were thinking about buying that %Field:GiftCategory% for Xmas?

Just visit our web site at www.xmas.com for a wide range of cool presents.

Santa

 

For each new message, the fields are replaced with those retrieved from the database, e.g.:

Dear John,

It is now July 20, so isn't it time you were thinking about buying that train set for Xmas?

Just visit our web site at www.xmas.com for a wide range of cool presents.

Santa

 

Default Field Values

If you use the personalization fields then you should also set the default field values.  These will be used whenever a particular user does not have an entry for that field in the database.  For example if you have used the %FirstName% field, but a user does not have the first name specified in the database then the default value will be used.

To set the default values, click on the Personalization button on the message editing toolbar and select 'Edit Default Field Values...'

You can also specify the following as default field Values:

%EMAIL_USER_NAME%:

When a name is not known for a particular user then the user name portion of the e-mail address will be used instead.  E.g. if the address is john@mycompany.com, then the 'John' will be used as the name

%EMAIL_DOMAIN_NAME%:

When a company name is not known for a particular user then the domain portion of the e-mail address will be used instead.  E.g. if the address is john@mycompany.com, then the 'Mycompany' will be used as the company name

 

Inserting Conditional Text

An advanced personalization feature is the ability to customize your message based on a database field of a member.  For example, if the country field is USA or the Messages Sent field is 0 (i.e. they are a new user).

To insert conditional text:

1. Select Home > New Email

2. On the message editing toolbar click the Personalization button and choose "Insert Conditional Text"

3. Select the database field to check

4. Choose how to evaluate the field.  The following options are available:

Note: If you have specified that each message has multiple recipients then will confirm changing this to single recipients (as each recipient will have a custom message).

Example 1: Using Different Links for American Recipients

%CONDITION:Country=USA%For more information, click here: http://www.myco.com/usa/index.html%CONDITION:ELSE%For more information, click here: http://www.myco.com/international/index.html%CONDITION:END%
 

Example 2: Special Comment for Very Active Members

%CONDITION:UserSentCount>50%We would like to thank you for your active participation in our mailing list!%CONDITION:END%
 

Date Fields and Conditional Text

When using date fields to insert conditional text you can specify a fixed date in your windows date format (e.g. 12/25/2012 for the U.S. Christmas) or dates relative to day using the "TODAY" keyword.  The date keyword can use date shifting, e.g. Today-1y is one year ago, Today-1w is one week ago.

%CONDITION:PurchaseDate>1/1/2011%You purchased after 2010%CONDITION:END%

%CONDITION:RecordDate>Now-1y%You joined in the last year%CONDITION:ELSE%You joined more than one year ago%CONDITION:END%

 

Nested Conditional Fields

You may also place conditions within conditions. Here's an example (with extra line breaks and colorization to make its meaning more obvious):

%CONDITION:Country=United Kingdom%


%CONDITION:SEX=Female%

Dear Madam

%CONDITION:ELSE%

Dear Sir

%CONDITION:END%


%CONDITION:ELSE%


%CONDITION:SEX=Female%

Hi Miss

%CONDITION:ELSE%

Hi Mister

%CONDITION:END%


%CONDITION:END%
 

ELSEIF Command

If you have many conditions you can also use the ELSEIF command

%CONDITION:Country=Australia%Gidday
%CONDITION:ELSEIF:Country=New Zealand%Kia Ora
%CONDITION:ELSEIF:Country=Italy%Ciao
%CONDITION:ELSE%Hello
%CONDITION:END%

 

Date Fields

Extra options are available when inserting date fields.  Date fields include %DATE% (today's date), custom fields of type "Date" or any column in an import file that ends with the name "Date" (e.g. "PurchaseDate").

Firstly, you can customize the appearance of dates to show, for example, just the month, year, or other custom formatting options.  This can be configured by selecting Personalization Options on the message sending toolbar.

You can also shift the date, e.g. showing the date tomorrow, or exactly one year ago.  To do this insert minus (prior to the date) or plus (after the date), a number and finally the period, e.g. "w" for week before the final %.  

Periods:

d

Day

w

Week

m

Month

y

Year

Examples:

%Date+1d%

Tomorrow

%Date-3y%

Three years ago

%Field:PurchaseDate+3m%

Three months after the date of purchase (a custom field of the member)

%Column:BirthDate+1w%

One week after their birthday (a column in an recipient's list file)

%DateCode+7d%

An encoded date for one week from today

 

Coded Date

A special date field is also available, %DateCode% which inserts a date that cannot be easily readable or changeable by end users.  The date can be easily decoded by a script on your web server.  

The format is as follows:

AABBCCDD

Where:

Year = 1980 + HexToInt(BB) / 3
Month =  HexToInt(CC) / 7 - 21
Day =  HexToInt(DD) / 7 - 5

There is also a checksum included to avoid casual modification:

AA = IntToHex(Year + Month + Day mod 200)

 

For example 2660BDAF would refer to 20 June, 2012.

 

Attaching Files Using Personalization Fields

Sometimes when sending you may need to attach files that are different for some recipients than others.  MLK allows the use of personalization fields anywhere in path of a file.  To do this:

1. Select Home > New Email to display the message editor

2. Hold down the Shift key and click the "Attach" button on the message sending toolbar

3. Specify the full path to your attachment.  Replacing as required with personalization fields
 

Example 1: You are sending to recipients in an Excel file and you have a column named "Attachment_1" that specifies a file to attach:

%COLUMN:Attachment_1%

 

Example 2: You have text files for each of your groups in the folder, C:\Attachments\

C:\Attachments\%Field:LastGroupJoined%.txt

 

Example 3: Japanese recipients receive C:\Attachments\Japan.txt.  All others receive C:\Attachments\Other.txt

%CONDITION:Country=Japan%C:\Attachments\Japan.txt%CONDITION:ELSE%C:\Attachments\Other.txt%CONDITION:END%

 

Note:
- If the personalized attachments points to a file that does not exist then MLK will send normally but without the attachment
- You can add as many personalized attachments as you like
- You can use the default values option to handle unspecified fields

 

Personalized Reply Address

MLK also supports personalization of the reply/sender address.  To do this:

1. Select Home > New Email to display the message editor

2. Click the "To" button

3. Check the box to "Override the Sender Address

4. Click "Specify" and enter your personalized email field as required

For example, let's say that we want the sending email to be the destination group name followed by @mycompany.com

%Field:LastGroupJoined%@mycompany.com

5. Optionally enter a personalized sender name

Let's say we want the name to be this recipients case manager which is read from a custom field specified for each user

%Field:Case_Manager%

6. Click OK

7. Use the Preview function to check it

 

Note:
- If an invalid email address is specified then the default email for the profile is used
- You can use the default values option to handle unspecified fields

 

Personalization Fields and Web Links

Two field modifiers are available:

.ENC: Encode the text so that it is safe in a web link

If you are inserting personalization fields into a web link, you should "encode" the text so that it does not contain unsupported characters (such as spaces).  You can instruct MLK to encode the text by specifying .ENC before the final % sign, e.g. %Company.ENC% will return the Company field with all unsafe characters encoded.

Here is an example web link that safely passes the full name and email of the user:

http://www.mycompany.com/cgibin/click.php?Email=%Email.ENC%&Name=%FullName.ENC%
 

.LINK: Convert a web site or an email address to a link

If you have fields that contain web or email addresses you can have MLK automatically convert them to clickable links in HTML messages by specifying .LINK before the final % sign, e.g. %Field:Web_Site.LINK% will create a clickable link to the web page specified in "Web_Site" field.

Note that you can combine both modifiers, e.g. %Field:Extra_Email.ENC.LINK%

 

Inserting Random Text

Sometimes you want your automated messages to appear like you've just typed it and not like impersonal, boilerplate text.  One way to handle this is to randomly change the text in your automated messages using the %RANDOM:X% field.

%RANDOM:X% inserts a number between 1 and X, e.g. %RANDOM:3% would insert 1, 2 or 3. You can specify any valid number between %RANDOM:2% and %RANDOM:1000000000%

Note: The random number is guaranteed to stay the same throughout the message to the current recipient (i.e. if you specify %Random:10% five times in your message, the first time MLK encounters %Random:10% in a message to a new recipient it generates a new random number, say 7, and all other %Random:10% calls in the message will also be replaced with 7.  If you want the random number to change everytime the field is used specify "?" before the max range value, e.g. %RANDOM:?100%

This is usually only used in combination with conditional text, e.g.

%CONDITION:Random:3=1%
How is the weather?
%CONDITION:END%

%CONDITION:Random:3=2%
Hope all is going well with you.
%CONDITION:END%

%CONDITION:Random:3=3%
Trust this message finds you in good health!
%CONDITION:END%

 

Previewing your Message

You can display a preview of the message that will show each of your recipients and how the personalization fields will be converted by clicking the Preview button on the message editing toolbar (or Alt+P).

 

See Also