Marketing Automation, Salesforce Marketing Cloud, SFMC Tips & Tricks

Track links that are AMPScript variables

Salesforce Marketing Cloud Tips

When you save links as part of an HTML code in an AMPScript variable, such as a paragraph containing a link to a page, you may face challenges in tracking these links.

Salesforce offers a great feature that allows tracking of such links using the “httpgetwrap” inserted right before the URL protocol.

href="httpgetwrap|https://martechnotes.com"

When dealing with AMPScript variables containing links for tracking, it is crucial to use the TreatAsContent() function instead of the v() function. This way, both the link and the tracking will work seamlessly.

%%[
SET @note = "Lorem ipsum dolor sit amet, consectetur adipiscing elit. <a href='httpgetwrap|https://martechnotes.com'>Vestibulum</a> eu lorem vel tortor mattis convallis. Etiam vulputate pharetra varius.</p>
]%%

%%=TreatAsContent(@note)=%%

GOOD TO KNOW

One important aspect to take into account when utilizing the “httpgetwrap” feature is its limitation in tracking only the first 100 unique URLs in the send. If you combine the prefix with Parameter Manager, it’s highly improbable that the click activity on these prefixed links will be fully tracked.

There is no longer a requirement to contact support for enabling this feature, as was the case in the past. Nowadays, the feature is automatically enabled on business units.

There is no longer a requirement to contact support for enabling this feature, as was the case in the past. Nowadays, the feature is automatically enabled on business units.

Oh hi there đź‘‹
I have a FREE e-book for you.

Sign up now to get an in-depth analysis of Adobe and Salesforce Marketing Clouds!

We don’t spam! Read our privacy policy for more info.

#AMPScript #email template
Marcel Szimonisz
Marcel Szimonisz
MarTech consultant As a marketing automation consultant, I specialize in problem-solving, process automation, and driving innovation for clients' marketing platforms.

I hold certifications in Adobe Campaign v6 (3x certified) and Salesforce Marketing Cloud (5x certified), as well as 1x Salesforce Associate certified.

Moreover, I serve as a community advisor for Adobe Campaign, providing expert insights and guidance.

Beyond my professional pursuits, I explore various programming languages, CMSs, and frameworks, enhancing my technical expertise and staying at the forefront of industry advancements.
Take a look at our subscription offering in case you are looking for a Marketing Automation Consultant.

Leave a comment

Your email address will not be published. Required fields are marked *

Similar posts that you may find useful

Adobe campaign tips and tricks
ACC Tips & Tricks, Adobe Campaign, Marketing Automation

ACC TIP | Export connection strings

less than a minute read

Whether you change your laptop or want to save actual configuration for your colleagues. You can easily achieve that by taking all connection strings as XML. ims – connection over adobe id SSO Also similar approach is to directly change the connection string file nlclient_cnx.xml that is located under your local AppData folder. To quickly […]

Continue reading
Adobe Campaign Classic OOP concepts in ES5
ACC Tips & Tricks, Adobe Campaign, Marketing Automation

Using OOP techniques in ES5: A Guide

3 minutes read

In this blog I will be exploring object-oriented programming (OOP) and Adobe Campaign Classic in ES5. As you may already know, Adobe Campaign Classic relies on ES5, the version of JavaScript specifically used by the platform. In ES5, there are a few limitations in terms of what you cannot do compared to newer versions of […]

Continue reading
Salesforce Marketing Cloud Tips
Marketing Automation, Salesforce Marketing Cloud, SFMC Tips & Tricks

Use client-side JavaScript in content block

1 minute read

Recently, I attempted to reference a content block from a cloud page that contained client-side JavaScript, and to my surprise, Salesforce Marketing Cloud removed it entirely. It looks like certain hook that triggers when you save your content block doesn;t like client side scripts and are completely removed like comments are when a executable program […]

Continue reading
SFMC tips and tricks
Marketing Automation, Salesforce Marketing Cloud, SFMC Tips & Tricks

SMFC TIP | NULL value comparison in IF statement

less than a minute read

If you have field in DE that its value is not always populated for a particular row (customer) and you test field value against any value cloud page will throw an 500 – internal server error. To fix this, you will simply need to add another AND-condition to test field value for NULL with NOT […]

Continue reading
Adobe Campaign Classic tips
ACC Tips & Tricks, Adobe Campaign, Marketing Automation

How to copy query conditions to another split

1 minute read

Perhaps you’ve encountered an unusual occurrence while attempting to copy complex query conditions to your clipboard. In some instances, only a portion of the content was copied, while in others, nothing was copied at all. I’ve personally faced similar situations over the years but never delved deeper into the matter. However, one day, I reached […]

Continue reading