Marketing Automation, Salesforce Marketing Cloud, SFMC Tips & Tricks

Invalid links in email template

Invalid links in email template

When the HTML template is used (loading your own HTML code) all the links that use query parameters (?a=b) will resolve to invalid links when they redirect upon user click. This happens when web analytics UTM tags are being attached to the delivery.

To resolve this issue all the links with additional query parameters has to be written to the href tag with use of AMPScript RedirectTo function.

<a href="%%=RedirectTo("https://martechnotes.com?parameter=1")=%%">Click here</a>

When you are using regular email template where you drag and drop components, the same is happening when you are using URL as variable or attribute in e.g. button component, such URLs will resolve to invalid ones.

Easy and same fix. Just wrap your url in RedirectTo

Redirect to when URL is attribute or variable

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 #programming
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

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

Fix HTTP post request wrong encoding

1 minute read

Recently, while working with the double opt-in process that employs an API to trigger transactional messages, I encountered an issue where Latin characters, characters with accent, were not captured correctly in the triggered send data extension. I have found that the SFMC HTTPPost uses, by default, WindowsCodePage 1252 encoding, which can cause issues with accented […]

Continue reading
Adobe Campaign Classic: Do loops in the workflow
Adobe Campaign, Marketing Automation

Do Loops in Adobe Campaign worfklow

4 minutes read

At times, there may be a need to execute the same workflow or its parts in loops. I’ll guide you through the process of creating your very own “for loop” within the Adobe Campaign workflow. loop While loop A “while loop” programming construct used to repeatedly execute a block of code as long as a […]

Continue reading
A futuristic digital artwork depicting a technician troubleshooting automated machines. The technician, adorned with a high-tech tool belt and a headset featuring a data-displaying visor, stands at the center of a dimly-lit tech facility. Around them are holographic screens presenting system diagnostics, error messages, and programming code. The background is bustling with a variety of machines and robots, some exhibiting malfunctions with sparks and error signals. The scene is illuminated by cool blues and greys, punctuated with orange and red highlights to emphasize the technical issues. Neon lights and exposed wiring add to the tech-savvy ambiance.
Automation studio, Marketing Automation, Salesforce Marketing Cloud, SFMC Tips & Tricks

Troubleshooting issues in automation studio

2 minutes read

Another series of troubleshooting automations in Salesforce Marketing Cloud. I will regurarly add any new additions that I have already resolved and spend great deal of time and life energy. So hope it will help resolve someones issues. I will try to add, throughout my daily life as an SFMC consultant, all the errors that […]

Continue reading
Exploring the Dynamic World of Email Marketing: Diverse Template Designs in Salesforce Marketing Cloud
Salesforce Marketing Cloud, SFMC Tips & Tricks

Proof multiple template variants in SFMC

2 minutes read

When working with dynamic email templates that can generate multiple unique variants of the email, you are most probably tasked to proof all the variants to your stakeholder for review. Create data extension When proofing email templates, traditionally, we select subscribers from production or testing data extensions used in the actual send. This process involves […]

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

Track links that are AMPScript variables

1 minute read

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. When dealing with […]

Continue reading