Email syntax allows you to dynamically include details about the recipient, sender or an attached entity in the email you are sending in XPLAN. Using syntax’s, you can produce custom emails from templates that contain client and user data, making each email personalized to each individual without the need to edit each email. When a report is generated, the Xmerge syntax is used to identify and insert data.
Email syntax can be used when sending an email or creating an email template.
Syntax can be manually entered into the body of an email, or by using the X button in the email editor.
Once within the Syntax editor, you will have 3 main options to help find the particular field you would like to have dynamically entered.
From/To – XPLAN’s email syntax allows you to prepopulate values with either the recipient name or the email sender’s name.
Categories – similar fields are grouped into categories in XPLAN to assist with searching. In this drop down menu, you can choose from a list of groups that provide a way to limit the results that flow through to the ‘Properties’ dropdown menu.
Properties – the ‘Properties’ dropdown menu is where you can select the field you want to have dynamically entered into the email you are sending in XPLAN.
While composing an email or email template, type the syntax in the body of the email. Depending on which entity you want to merge details about, the following syntax is used:
Within the syntax editor, you have different options to insert the desired output:
Before you send an email, you can click ‘Preview’ to see a preview of the email, including the merged details from the email syntax.
When creating or editing an email template, you can click ‘Syntax Check’ to view an example email output using the email syntax. When you do a Syntax Check you keep a lookout for the word “Error” as this indicates that the syntax coding has a problem.
This can be used as a way of checking that the coding will work.
Below are different types of Email coding syntax examples that you may want to use when creating a template.
<:=datetime_merge:> e.g. 05 June 2013 01:24:23 PM
<:=datetime_merge.date:> e.g. 05 June 2013
<:=datetime_merge.time:> (12 hour time) e.g. 02:24:21 PM
<:=datetime_merge.time24:> (24 hour time) e.g. 15:24:24
<:for item in $recipient.contact:>
<:if str(item.type)=='Home Phone':>
<:=item.value:>
<:end:>
<:end:>
<:for item in $recipient.contact:>
<:if str(item.type)=='Work Phone':>
<:=item.value:>
<:end:>
<:end:>
<:for item in $recipient.address:>
<:if str(item.type)=='Postal':>
<:=item.street:>
<:=item.suburb:> <:=item.state:> <:=item.postcode:>
<:end:>
<:end:>
<:=$recipient.preferred_email:>
<:for item in $recipient.address:>
<:if str(item.type)=='Residential':>
<:=item.street:>
<:=item.suburb:> <:=item.state:> <:=item.postcode:>
<:end:>
<:end:>
<:=$recipient.preferred_name:>
<:if $recipient.has_partner:> and <:=$recipient.partner.preferred_name:>
<:end:>
<:let has = False:><:if $recipent.first_name:><:=$recipient.first_name:>
<:if $recipient.has_partner:> and <:=$recipient.partner.preferred_name:><:let has = True:>
<:end:>
<:end:>
<:if not has:><:=$recipient.superfund_name:><:=$recipient.company_name:>
<:=$recipient.trust_name:>
<:end:>
<:=$attached_client.opt_in_status:>
<:=$sender.first_name:> <:=$sender.last_name:> <:=$sender.jobtitle:>
<:=$sender.employer:>
<:=$recipient.adviser.first_name:> <:=$recipient.adviser.last_name:>
<:=$recipient.adviser.employer:>
<:=$recipient.adviser.jobtitle:>
<:=$recipient.adviser.preferred_email:>
<:for item in $recipient.adviser.contact:> <:if item.type=='Work Phone':><:=item.value:
<:end:>
<:end:>
<:for item in $recipient.adviser.contact:><:if item.type=='Mobile Phone':><:=item.value:>
<:end:>
<:end:>