Optional content allows information to be presented to customers based on their attributes or their behaviors. These sections can be a powerful personalization technique and allow for varied content without the creation of additional segments or campaigns.
Create optional content
- Go to Activation.
- Create a new campaign or edit an existing campaign.
- Add or edit an email touchpoint.
- Select the element, column, or section you want to make optional.
- Under Details, set the condition that determines if the content is shown under the Scripting section
- Click Save.
Optional content examples
The following examples serve as an introduction to how you can use optional content. More advanced logic is possible through the use of custom liquid. Reach out to your customer success manager before proceeding with advanced personalization.
Birthday month
The following example is based on a default Customers field and only appears if it is the customer's birthday month.
- Under Setup for the section, create a variable called current_month:
{% assign current_month = now | date: “%m” %}
- Use Condition to determine if the current_month is the same as the customer's birthday month.
customer.dob_month == current_month
- You could also create a different section for customers whose birthday is not the current month by using the following statement in Condition instead:
customer.dob_month != current_month
VIP status
The following example is based on a custom customer field and only appears if the customer is considered a VIP.
- Create a custom True/False customer field called VIP.
- Reference the VIP attribute in Condition to determine if the customer has the VIP value.
customer.vip == true
- You could also create a different section for customers who are not considered VIPs.
customer.vip != false
Rating system
The following example is based on a custom product field and appears when a product is associated with a certain rating.
- Create a custom product field called Rating using the Number field type. For this example, the rating system is from 1 to 5 stars.
- Add an additional image element in the dynamic product grid of your touchpoint. Position and resize accordingly. For this example, the rating will be shown as a collection of stars.
- Set the Image URL of the additional image element. In this case, it will be {{star_image}}.
- Upload the images that represent your ratings to an accessible source.
- Add the Liquid shown below to the setup block of the dynamic grid. Replace the generic example titles and links with references to your images.
{% assign rating = product.rating %} {% if rating == 3 %} {% assign star_image = 'https://url_to_my_asset/3_star_image.gif' %} {% elsif rating == 4 %} {% assign star_image = 'https://url_to_my_asset/4_star_image.gif' %} {% elsif rating == 5 %} {% assign star_image = 'https://url_to_my_asset/5_star_image.gif' %} {% else %} {% assign star_image = 'https://url_to_my_asset/less_than_2_star_image.gif' %} {% endif %}
- Edit, Save, and Go Live with the campaign.
Article is closed for comments.