Use IF Else condition within Process Email Template

Hi,

I tried to use below if else one-by-one in process email template html code but email comes with code and conditions are not working.

1. {if $check_service_c=="Yes"} sometext {/if}

2. <!--{if $check_service_c=="Yes"} sometext {/if}-->

3. <!--{{#if {::Leads::check_service_c::} == "Yes" }} sometext {{else}} sometext 2{{/if}}-->

4. {{#if {::Leads::check_service_c::} == "Yes" }} sometext {{else}} sometext 2{{/if}}

My requirement is, If checkbox is checked than show sometext

Any help will be highly appreciable

Regards

Parents
  • I assume $check_service_c is a checkbox. I believe checkboxes evaluate to true/false.

    {if $check_service_c} optionA {else} optionB {/if}

    this syntax works in PDF manager, which also uses smarty:

    {if $fields.check_service_c} optionA {else} optionB {/if}

    I hope this helps,

    FrancescaS

Reply
  • I assume $check_service_c is a checkbox. I believe checkboxes evaluate to true/false.

    {if $check_service_c} optionA {else} optionB {/if}

    this syntax works in PDF manager, which also uses smarty:

    {if $fields.check_service_c} optionA {else} optionB {/if}

    I hope this helps,

    FrancescaS

Children
No Data