Personalization
To personalize message content we developed a template syntax that is based on a custom version of Smarty (a php based template language). Using Smarty, you are able to customize message content unique to each contact by taking advantage of variables, link functions, conditional content, data looping and much more. The sections and articles below will give you explanations, examples and use cases.
Cordial Template Syntax Overview
Variables
- Smarty Variables
- System Variables
- Account Variables
- Contact Variables
- Assigning Variables
- External Variables (API Sending)
Link Functions
- Link Functions Overview
- Optout Link
- Adding Tags to Links
- Naming a Tracked Link
- Link Append Defaults via UI
- Link Appends via Smarty
Conditionals and Loops
- Conditionals and Loops Overview
- {if} statements
- {foreach} statements
- Randomize Content
- Calculate Distance Between Postal Codes
- Sort an Array
Reusable HTML Content (Includes)
Cordial Utilities
- Cordial Utilities Overview
- Cordial Utilities Reference Page
- Get Supplements (getSupplementRecords method)
- Get Products (getProducts method)
- Get Order Data
- Get Event Data (getEventRecords method)