Follow

Nested Logic to Include Articles

You can use Template If/Then/Else logic and subscriber data fields to determine which Article to include in a template. This option is available in version 8.3 and later.

To use Logic to include Articles

If you have multiple articles and want to include an article in a template based on a subscriber's data, use the following example:

Setup:

Five articles exist as follows: English, German, Spanish, French, Italian Subscriber Custom Field exists called "language".  This field contain one language preference, but is not restricted to the languages above.

Rule:

Display the article that matches the Subscriber language preference.  If the preference does not match an article name, then display the "English" article.

Code:

%%if $language = "German" then includearticle "German" else if $language = "Spanish" then includearticle "Spanish" else if $language = "French" then includearticle "French" else if $language = "Italian" then includearticle "Italian" else includearticle "English"%%  

Was this article helpful?
0 out of 0 found this helpful
Have more questions? Submit a request

Comments

Powered by Zendesk