Scroll down for the Step-by-Step Guide on how to add Merge Tags
KEY TERMS & TIPS:
What are Merge Tags?
Transaction-specific data/code that you can insert into your HTML Email and Ticket Templates.
This could be data such as event name, customer name, ticket specifics, etc.
There are different kinds of Tags depending on the data that you want to include, see below.
Global Tags
These are singular values that are unrelated to a specific item in a transaction, but related to the transaction as a whole, e.g:
Organisation name
Customer name
Total value of transaction
See our Step-by-Step guide below for how to add them to your Templates.
See here for the full list of Global Tags that are available.
Loop Tags
These are values that tend to be related to a specific item in a transaction, e.g.:
Event name
Event venue
Ticket price for event
Loop tags need to be placed into a Loop in your HTML for it to work properly.
See our Step-by-Step guide below how to add them to your Templates.
See here for the full list of Loop Tags that are available.
Conditionals
These are Tags that are conditional depending on what has been ordered, e.g.:
Discount value - if a discount has been applied
External price adjusters (external only - not internal)
These can be achieved by using 'if' statements on your HTML.
See our Step-by-Step guide below for how to add them to your Templates.
How do I add Merge Tags to my Templates?
You can insert these into HTML Templates using the list of Tags that we make available to you.
See our Step-by-Step guide below for the full instructions.
See here for the full list of Tags that are available.
Why isn't my Merge Tag working?
This may be because Loop tags are being placed outside of Loops - see our Step-by-Step guide below for more info.
NOTE - as the ticketing software provider, we deliver and maintain the ticketing system. We do not provide template design and as such we would suggest going to an external HTML designer for detailed help with HTML templates.
We recommend unlayer for designing HTML templates.
ChatGPT is also very helpful for specific HTML queries.
What is an Email Template?
Design what your emails look like to your customers by creating templates.
These could be booking confirmation emails, pre/post show emails, etc.
See here for more info.
What is a Ticket Template?
Design what your tickets look like to your customers by creating templates.
See here for more info.
---
STEP-BY-STEP GUIDE:
1. Go to the Tools page on the left hand side and click Email or Ticket Templates, then New Email/Ticket Template
2. Select existing Template from the list or create a new one
3. Add relevant details - name, description, subject line, etc
4. Select HTML Template Type
5. When entering HTML Template, add your Merge tags:
a) Global Tags:
-
- Global Tags can be inserted into the Template by referencing the right tag and simply placing it inside two curly brackets:
{{ YOUR_TAG_HERE }}
-
- Here's an example of some in use:
<p>Hello {{ CUSTOMER.FNAME }},</p>
<p>Thank you for buying tickets from {{ ORGANISATION.NAME }}, we can't wait to see you at our venue.</p>
<p>Your transaction with us came to a total of {{ ORGANISATION.CURRENCY_SYMBOL }}{{ TRANSACTION.TOTAL }}.</p>
b) Loop Tags:
-
- Loop Tags need to be placed into a Loop for it to work correctly. A Loop looks like this:
{% for ticket in TRANSACTION.TICKETS %}
<-- Tags related to tickets are now available provided they are entered before the endfor loop close below -->
{% endfor %}
-
- Once you have placed your Loop, you can add some of the tags that are available to you inside that Loop:
{% for ticket in TRANSACTION.TICKETS %}
<-- Tags related to tickets are now available provided they are entered before the endfor loop close below -->
<p>Your Tickets for {{ ticket.EVENT.NAME }} at {{ ticket.EVENT.VENUE }}:</p>
<p>Ticket Price: {{ ORGANISATION.CURRENCY_SYMBOL }}{{ ticket.FACE_VALUE }}</p>
<p>Tax: {{ ORGANISATION.CURRENCY_SYMBOL }}{{ ticket.TAX }}</p>
<p>Total: {{ ORGANISATION.CURRENCY_SYMBOL }}{{ ticket.GROSS }}</p>
</p>
{% endfor %}
-
-
NOTE - for these to work correctly, the identifier in the Loop (i.e. ’ticket’ in the example above) needs to be placed in front of the Tag, like this:
{{ ticket.FACE_VALUE }}
-
-
-
NOTE - If a Merge Tag isn’t valid or doesn’t return any values, nothing will be shown in its intended position. This may be related to placing Loop Tags outside of Loops.
The following shows an example of when a Loop tag is placed outside of a Loop (e.g. after an 'endfor' - not before as it should be), that would result in it not displaying the desired data:
{%for ticket in TRANSACTION.TICKETS%}
<-- Tags related to tickets are now available provided they are entered before the endfor loop close below -->
<p>Your Tickets for {{ ticket.EVENT.NAME }}:</p>
<p>Ticket Price: {{ ORGANISATION.CURRENCY_SYMBOL }}{{ ticket.FACE_VALUE }}</p>
<p>Tax: {{ ORGANISATION.CURRENCY_SYMBOL }}{{ ticket.TAX }}</p>
<p>Total: {{ ORGANISATION.CURRENCY_SYMBOL }}{{ ticket.GROSS }}</p>
</p>
{% endfor %}
<-- The below tag would not be valid as it is not included in the ticket loop -->
<p>Venue Name: {{ ticket.EVENT.VENUE }} </p>
-
c) Conditionals:
-
- There are some instances where you may want sections of the ticket or the email to be conditional depending on what has been ordered. These can be achieved by using ‘if’ statements. Here are some examples:
“I want a ticket discount value to show but only if there has been a discount applied” - in this instance, you would use something as follows:
{% for ticket in TRANSACTION.TICKETS %}
<p>Ticket Price: {{ ORGANISATION.CURRENCY_SYMBOL }}{{ ticket.FACE_VALUE }}</p>
<p>Tax: {{ ORGANISATION.CURRENCY_SYMBOL }}{{ ticket.TAX }}</p>
<-- The following if statement will mean that the next p tag will only show if there has been a discount on the ticket -->
{% if ticket.DISCOUNT.AMOUNT > 0 %}
<p>Discount: {{ ORGANISATION.CURRENCY_SYMBOL }}{{ ticket.DISCOUNT.AMOUNT }}</p>
{% endif %}
{% endif %}
<p>Total: {{ ORGANISATION.CURRENCY_SYMBOL }}{{ ticket.GROSS }}</p>
{% endfor %}
”I want to show a price adjuster but only if it’s an external one, e.g. an external booking fee”:
{% for ticket in TRANSACTION.TICKETS %}
<p>Ticket Price: {{ ORGANISATION.CURRENCY_SYMBOL }}{{ ticket.FACE_VALUE }}</p>
<-- The following loop will identify price adjusters on the ticket -->
{% for price_adjuster in ticket.PRICE_ADJUSTERS %}
<-- The following if statement says that if there are any price adjusters that are external -->
{% if price_adjuster.EXTERNAL %}
<-- The following tags will then display for any external price adjusters -->
+({{ price_adjuster.NAME }}: {{ ORGANISATION.CURRENCY_SYMBOL }}{{ format(price_adjuster.RATE }}
{% endif %}
{% endfor %}
<p>Tax: {{ ORGANISATION.CURRENCY_SYMBOL }}{{ ticket.TAX }}</p>
<p>Total: {{ ORGANISATION.CURRENCY_SYMBOL }}{{ ticket.GROSS }}</p>
{% endfor %}
6. When you have finished entering your HTML, click Submit
7. See here for our Full Tags List, where you can choose the Global and Loop Tags we have made available for your Templates
Comments
0 comments
Please sign in to leave a comment.