TracMark Syntax

CREATED: MAY 13, 2016  |  LAST UPDATED: JUL 19, 2016  |   BOOKMARK  |   COPY URL

TracMark is a technical language or code used for personalising, calculating, tracking and building conditional email content based on available data. Customer behaviours and interactions can be tracked and specific targeted content sent to customers based on their interactions. TracMark is the language or code that translates the instruction into real world context or 'human language' using merge feilds.

Merge Fields

The Merge fields are attributes used to merge or add contact data with an email to personalise the content. The TracMark identifies the matching column header within the data spreadsheet loaded in the platform and adds the data in that column to the specified position of the tracMark for each individual contact. You can see how this works in the below examples;

Merge Field TracMark Syntax Output
Name [!Name!] Chris
DOB [!DOB!] 01/01/1970
Email [!Email!]

Dynamic Content Builder and Conditions

Dynamic content is created using conditions using the data you have collected. For example if you would like to send an email to females only would use a dynamic condition to check the gender which would automatically segment the list based on results returned.

Simple if condition:

 [[IF [!GENDER!] IS 'Female']] 
Send content or information relating to females
Send content or information relating to males
 [[END IF]]

Multiple Condition using else if :

Multiple conditions can be used to provide even more targeted content.

 [[IF [!State!] IS 'NSW']] 
 [[ELSE IF [!State!] IS 'QLD']] 
[[END IF]]

Using Switch (by) construct to check against single value:

Content can be switched out to replace other content options based on set conditions.

[by State]] 
[[when 'NSW']]
[[when 'QLC']]
[[when 'vlc']]
[[end by]]

Check against numeric values for validating:

Contacts can be validated based on numeric values such as setting age requirements. For example; if they do not meet the age requirement they will not qualify to receive the content.

[[IF [!dateOfBirth!].ageInYears() > 18]]
You are under age and not authorized
Welcome user you are authorized to purchase ticket for this cinema
[[end if]]

Using multiple & conditions:

Multiple conditions can be applied to further refine eligibility.

[[IF [!State!] IS 'NSW' and [!dateOfBirth!].ageInYears() >18 and [!Gender!] is 'Male']]
You are eligible for this offer
You are not eligible for this offer
[[end if]]

Using OR conditions:

OR conditions can also be set to qualify and exempt contacts depending on restrictions.

[[IF [!State!] IS 'NSW' or State IS 'QLD']]
You are eligible for this offer
You are not eligible for this offer
[[end if]]

Using AND with OR conditions:

Although there is the standard order of operations applied when mixing AND and OR, best practice is to explicitly control the evaluation order by using ()

[[(IF [!State!] IS 'NSW' or State IS 'QLD') and Age IS 26]]
You are eligible for this offer
You are not eligible for this offer
[[end if]]

Boolean Field Condition:

Boolean fields will accept only exact condition matches of yes or no. If the data is missing then it will add new data to the field.

*Include the entire contents of any url [[INCLUDE '']]

[[IF Signup]]
Subscribed User
New User
[[END IF]]
[[if not signup]]
[[end if]]

* Include the entire contents of any url [[INCLUDE '']]

Important Functions:

The following are some common TracMark codes you may want to use in your emails:

[!unsubscribe()!]: Unsubscribe from the system

<a href="[[unsubscribe()]]" data-track-link="false">Unsubscribe</a>

[!unsubscribeList(482219)!]: Unsubscribe from the contact list

<a href="[[unsubscribeList(482219)]]" data-track-link="false">Unsubscribe from list</a>

[!unsubscribeBlocklist()!]: Unsubscribe from the Blocked list

<a href="[!unsubscribeBlocklist()!]" data-track-link="false">Unsubscribe to blocklist</a>

[!onlineVersion()!]: function to view email online version on click

<a data-track-link="false" href="[!onlineVersion()!]">online</a>

NewInclusion of contact lists and contact segments as personalization values
This feature brings in the capability to use contact lists and segments and also to use these as Boolean values in text and in tracmark

[!!] (id should be replaced with the actual ContactList ID - [!ContactList.123456!])
[!!] (id should be replaced with the actual ContactSegment ID - [!ContactSegment.123456!])