Add Dynamic Content in Marketing Campaigns Templates

Objective

Twilio SendGrid Marketing Campaigns allow users to add dynamic content to their templates.

Product

Email 

Procedure

This is achieved using greaterThan with else and length helpers. These allow you to iterate through a string or array. Here's some example code of what this might look like:

<p>{{#greaterThan (length newsletter_items) 0}}
It looks like you still have some items in your cart. Sign back in to continue checking out.
{{else}}
Thanks for browsing our site. Come back and see us soon.
{{/greaterThan}}</p>

For full details, see our doc Adding Dynamic Content with Handlebars in Marketing Campaigns.

Have more questions? Submit a request