Litmus tracking code error | Community
Skip to main content
May 29, 2014
Question

Litmus tracking code error

  • May 29, 2014
  • 8 replies
  • 6052 views
I have been adding the tracking code provided by Litmus within the body of my Marketo email. However, Marketo keeps automatically altering the code after I save it and then I reaceive the following error in Litmus.
Looks like we found the tracking code, but it wasn't fully there. Try pasting the code again and resend your email.
Has anyone else had this issue? Is there a way to resolve this from happening?
This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.

8 replies

Matt_Stone2
Level 9
May 29, 2014
I've been able to use the Litmus tracking code, but it's a little trickier than their instructions let on. Here's how you do it:

  1. When setting up your email program in Marketo, click “My Tokens” on the program dashboard
  2. Add an “Email Script” token
  3. Name the token and click “Click to edit”
  4. On the right, underneath “Standard Objects,” expand the “Lead” category. Find the “Email Address” field and check the box
  5. In the empty script space on the left of this same page, paste in the tracking code provided by Litmus
  6. In the Litmus code, replace every instance of {{lead.Email Address}} with ${lead.Email}
  7. Click Save to close the lightbox window and click “Save” again on the tokens page
  8. Make note of the name of the token (e.g. {{my.Litmus Analytics}} )
  9. Open the email you want to track (not the template, but the email itself within Marketing Activities).
  10. At the very bottom of your email, place your new script token. You can also add default information to match Litmus’ (e.g. {{my.Litmus Analytics:default=noemail}} )
  11. When the email is sent, the script will be placed into the email at that spot without the Marketo WYSIWYG editor modifying the code and without having to alter your email template
Hiram_Cruz
Level 2
September 28, 2015

Hey Matt, thanks for posting this.

For Step #6, I don't see any {{lead.Email Address}} in the tracking code but I see {{lead.Email Address:default=noemail}}

Should I replace the whole thing so it just reads like this:

${lead.Email}

Or

Should it read like this: ${lead.Email}:default=noemail}}

Also, for step #10-- I inserted the token at the "bottom of the email" but when I send it out I get the title of the token in text:

How should I insert the token without it displaying it as text???

Regards,

- Hiram

Matt_Stone2
Level 9
September 28, 2015

Hi Hiram,

For your first question -- yes, replace the entire thing.

For your second question -- did you use any dynamic content in the email? If you did, you will be unable to use the tracking code at the same time. It's an unfortunate limitation of Marketo.

May 30, 2014
Hey Alison,

I've noticed the same thing. Marketo parses the HTML (including your litmus snippet) and then takes the <style> code block generated, segregates it away from the tracking pixel <div> and <img> tag it also makes. 

The real question is, have you tested a Litms-tracked send and found that you're not tracking any behavior from your audience?

I really like what Matt has outlined above. That's a great solution to the problem and worth trying out.
June 3, 2014
It should be noted that in order for the tracking code to work, you can't use Send Sample. You have to create a new lead with the testing address provided by Litmus using the instruction in Step 3 found here:
https://community.marketo.com/MarketoArticle?id=kA050000000L7c9CAC

After that, you can test your email using a Single Flow Action:
https://community.marketo.com/MarketoArticle?id=kA050000000KytDCAS
November 3, 2014
I spent about 4 hours working on this and still can't make it work. Customer support was completely unhelpful and gave me canned answers.
Matt_Stone2
Level 9
November 3, 2014
Hi Dede, did you follow my step-by-step instructions and still weren't able to get it to work?
Matt_Stone2
Level 9
November 3, 2014
Also, it's important to note that if you use any sort of segmentation within your email, you CAN'T use email scripts (thus my method wouldn't work).
April 28, 2015
Hi Matt S, in regards to your last comment about segmentation within the email, are you referrinf to dynamic content for different audiences?
Matt_Stone2
Level 9
April 29, 2015
Hi Alan -- that's correct. You can't use dynamic content and email scripts at the same time, unless Marketo has changed that in the past few months.