Recent searches
No recent searches
Multi-Select Liquid Markup Case Statement
Answered
Posted Apr 12, 2022
I am attempting to determine what values are contained in a multi select and based on that, send certain content in an email through Dynamic Content. What is the best way to traverse the values of the Multi Select?
{% case ticket.ticket_field_80818947 %}
{% when 'VALUE 1' %}
<p>Content for VALUE 1</p>
{% when 'VALUE 2' %}
<p>Content for VALUE 2</p>
{% when VALUE 3' %}
....
{% endcase %}
0
1
1 comment
Christopher Kennedy
The multi-select value will be a string of the selected tag values for the field separated by a space. The simplest approach to evaluating the selected values involves using an if statement with the contains operator. So from your example:
If the selected value is VALUE_1 or VALUE_2, the content for that value is displayed. If both are selected, then the content for both values are displayed.
Best,
0