Cheat Sheet - Campaign versus Marigold Engage

This page contains a quick guide on how some functions, variables and components are used within Campaign versus Marigold Engage. It does not replace the dedicated topics, but can be used as 'cheat sheet'.

 

MASECTION / Conditional expression

Campaign:

Copy
<div id="MASECTION" MACONSTRAINT="ID=0" MAHIDEDIV="true"></div>

Engage:

Copy
<sg:conditional expression="eq([MASTER.ID],toint('0'))" id="row-043013eb-db1d-429a-bc0f-6b79783a1a19"></sg:conditional>

 

IF function

Campaign:

Copy
~(IF(ID=0,'anonymous','known'))~

Engage:

Copy
[%if(eq([MASTER.ID],toint('0')),'anonymous','known')%]

 

Field value from user list

Campaign:

Copy
~FIELDNAME~

Engage:

Copy
[%[MASTER.FIELDNAME]%]

 

Field value from profile extension

Campaign:

Copy
~PROFILE_EXTENSION.FIELDNAME~

Engage:

Copy
[%[PROFILE_EXTENSION.FIELDNAME]%]

 

Field value from actionlist

Campaign:

Copy
~ACTIONLIST.FIELDNAME~

Engage:

Copy
[%eventValue('FIELDNAME')%]

 

Field value from container / repeater

Campaign:

Copy
~ITEM.FIELDNAME~

Engage:

Copy
[%itemValue('FIELDNAME')%]

 

Field value from parameter

Campaign:

Copy
~@FIELDNAME~

Engage:

Copy
[%requestValue('FIELDNAME')%]

 

ARTICLE_PROPERTY / itemValue

Campaign:

Copy
~(ARTICLE_PROPERTY('CONTAINERNAME',0,'VAR'))~

Engage:

Copy
[%itemValue('REPEATERNAME',toint('0'),'VAR')%]

 

Variables

Campaign:

does not exist

Engage:

Copy
[%[VARIABLE.VAR]%]

Engage variables are created on message level. When using these variables in a template, they will not yet allow free-form values in there. If however you need to change the color in your email using free-form data, then use a repeater surrounding your entire message and treat the message as one big article. Creating an article will allow free-form data. The article_list would be called 'MAILSETTINGS'.
See the example 'Repeater in Repeater' below.

 

Content Blocks

Campaign:

does not exist

Engage:

Content Blocks will be dynamically populated when the variable used in the Content Block is present in the message and has a value defined for it.

Copy
=>
[%[VARIABLE.VAR]%]

Content Blocks are a powerful tool. A Content Block is basically a snippet of HTML that can be used and re-used all over.
See this topic for more info on Content Blocks.

 

Campaign:

Copy
<a href="~PROBE(0)~" />

Engage:

Copy
<a href="[%LINK(0)%]" /> OR <a expr:href="LINK(0)"></a>

 

Container / Repeater

Campaign:

Copy
 <div id="MACONTAINER" macontenteditable="FALSE" maconstraint="" maparameter="ARTICLES" matype="" mahidediv="true">
     <div id="MAHEADER" macontenteditable="true"></div>
     <div id="MAITEM" macontenteditable="true"></div>
     <div id="MAFOOTER" macontenteditable="true"></div>
     <div id="MANOMATCH" macontenteditable="true"></div>
 </div>

Engage:

Copy
<sg:repeater columns="0" dataselection="ARTICLES" id="ARTICLES">
    <sg:repeaterheader visible="false"></sg:repeaterheader>
    <sg:repeateritem content-value="" id="item-34bb229d-dbc9-4bbb-94ef-d172ea68d9ed" name="Layout-1"></sg:repeateritem>
    <sg:repeaterfooter visible="false"></sg:repeaterfooter>
    <sg:repeaterempty visible="false"></sg:repeaterempty>
</sg:repeater>

 

Container in container / Repeater in repeater

Campaign:

<!-- not gonna state the obvious -->

Engage:

This can't be done through the Engage UI.

Copy
What can be done though is using the following html code :
<sg:repeater columns="0" dataselection="MAILSETTINGS" id="MAILSETTINGS">
    <sg:repeaterheader visible="false"></sg:repeaterheader>
    <sg:repeateritem content-value="" id="item-34bb229d-dbc9-4bbb-94ef-d172ea68d9ed" name="Layout-1">
        <p style="background-color:#[%itemValue('MAINCOLOR')%]; color:#[%itemValue('CUSTOMERCOLOR')%];">
            MAINCOLOR: [%itemValue('MAINCOLOR')%]
            CUSTOMERCOLOR: [%itemValue('CUSTOMERCOLOR')%]
            <br>
        <ul>
            <li>
                NAME: [%itemValue('MOVIETRAILER',0,'NAME')%]
                <br>
                TRAILER_URL: [%itemValue('MOVIETRAILER',0,'TRAILER_URL')%]
                <br>
                FALLBACK_IMG: [%itemValue('MOVIETRAILER',0,'FALLBACK_IMG')%]
            </li>
            <li>
                NAME: [%itemValue('MOVIETRAILER',1,'NAME')%]
                <br>
                TRAILER_URL: [%itemValue('MOVIETRAILER',1,'TRAILER_URL')%]
                <br>
                FALLBACK_IMG: [%itemValue('MOVIETRAILER',1,'FALLBACK_IMG')%]
            </li>
        </ul>
        </p>
    </sg:repeateritem>
    <sg:repeaterfooter visible="false"></sg:repeaterfooter>
    <sg:repeaterempty visible="false"></sg:repeaterempty>
</sg:repeater>
<sg:repeater columns="0" dataselection="MOVIETRAILER" id="MOVIETRAILER">
    <sg:repeaterheader visible="false"></sg:repeaterheader>
    <sg:repeateritem content-value="" id="item-2185007b-97d7-4a40-9726-a2863ccea163" name="Layout-1">
        <div style="display:none!important;">
            NAME: [%itemValue('NAME')%]
            <br>
            TRAILER_URL: [%itemValue('TRAILER_URL')%]
            <br>
            FALLBACK_IMG: [%itemValue('FALLBACK_IMG')%]
        </div>
    </sg:repeateritem>
    <sg:repeaterfooter visible="false"></sg:repeaterfooter>
    <sg:repeaterempty visible="false"></sg:repeaterempty>
</sg:repeater>

 

Labels

Campaign:

Copy
~#LABELNAME~

Marigold Engage:

Copy
[%label('DICTIONARY_NAME','LABEL_NAME')%]