Twig Issue

mike-gcs

Member
I am having a weird issue. Twig when used in an email works on the test email, but not on the actual campaign send. I have already searched this forum and all seems well based on the test working. Is there something I am missing?

Here is the Twig:
HTML:
<td style="text-size-adjust: 100%; text-align: right;padding:5px;">{% if CRFLAG == 'Y' %} Yes {% else %} No {% endif %}</td>

Here is the tag from the custom fields:
1724361270974.png
 
@mike-gcs - I ran some tests for this over the weekend but I couldn't reproduce the problem. From what I see, it seems the twig content is ignore completely, like it is not parsed at all.
Any way for me to check this on the server? if so, please add the connection info in a support ticket for both backend app and (s)ftp access and I'll take a look.
 
UPDATE:
Using twig logic inside of a URL will cause the issue I was having.
Test emails do not create unique links. Live emails create the unique link and, in this case, overwrote my twig and gave an error message.

Lesson learned:
URL links (hyperlinks) process before twig logic. Do not use twig in the URL. Instead use multiple URLs to achieve the same result.
 
Back
Top