Email Tracking | Community
Skip to main content
November 21, 2013
Question

Email Tracking

  • November 21, 2013
  • 12 replies
  • 3799 views
We are wanting to add the code shown below to track the emails. However, the company that provided the code told us that we need to "switch off CSS inlining" in Marketo prior to adding this code. This is because Marketo is removing most of the code and leaving only the last line. Please advise on how to "switch off CSS inlining" and make this work.

Below is the code we are trying to add to our emails:

<style>@media print{ #_t { background-image: url('https://pwej2oqz.emltrk.com/pwej2oqz?p&d={{lead.Email Address:default=noemail}}');}} div.OutlookMessageHeader {background-image:url('https://pwej2oqz.emltrk.com/pwej2oqz?f&d={{lead.Email Address:default=noemail}}')} table.moz-email-headers-table {background-image:url('https://pwej2oqz.emltrk.com/pwej2oqz?f&d={{lead.Email Address:default=noemail}}')} blockquote #_t {background-image:url('https://pwej2oqz.emltrk.com/pwej2oqz?f&d={{lead.Email Address:default=noemail}}')} #MailContainerBody #_t {background-image:url('https://pwej2oqz.emltrk.com/pwej2oqz?f&d={{lead.Email Address:default=noemail}}')}</style><div id="_t"></div>
<img src="https://pwej2oqz.emltrk.com/pwej2oqz?d={{lead.Email Address:default=noemail}}" width="1" height="1" border="0" />
This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.

12 replies

November 21, 2013
I would like to start with a reminder: MS-Outlook does not render background images therefore <style>@media print{ #_t { background-image is not going to work regardless the way the email is defined. It is a known and documented limitation

http://www.campaignmonitor.com/css/

CSS are valuable for landing pages. They define font styles, colours and other properties once and then just referenced when needed.

Emails  need the styles defined for each element, such as

<td width="1" valign="top" bgcolor="#A8A8A8" style="border-collapse: collapse;"><img src="http://example.com/images/spacer2.gif" width="1" height="40" border="0" style="border: 0; display: block;"></td>

That sort of defintion is repeated for every element.
November 21, 2013
Adding some clarification to the question - the tracking code is for deliverablilty tracking via Litmus and not for image rendering. Litmus offers custom code for every email provider.  When we added thier code to a marketo email, marketo removed the majority of the link breaking the tracking.  Litmus suggested that we switch off CSS inlining to prevent this issue.  Suggestions on how to troubleshoot or resolve?
November 22, 2013
Are you trying to add it using the WYSIWYG editor in the email builder? Or are you adding it to the actual HTML template code in the email templates area of design studio?
November 22, 2013
Adding this to the HTML template code
November 22, 2013
Bummer--I guess I didn't realize that Marketo was automatically inlining CSS in email templates. That's definitely something I would like to have the ability to turn off.

So when you try to save the template, are you getting a popup that looks something like this: http://community.marketo.com/MarketoResource?id=kA650000000GuJ4CAK?

Do you hit "Automatic Fix" or "Cancel"?  Maybe the "Automatic Fix" bit is where it messes with your CSS? I get that error every once in awhile, and it's usually in relation to something I purposefully tried to include. When that's the case I usually click cancel.
November 22, 2013
The html template we have we are running through Litmus. This then prompts to add the code for tracking. We add this in Marketo. Copy and paste the html code with the Litmus tracking code and in Litmus receive a message saying that the code is not complete. After review, we see only the last line is present. Marketo removes most of the tracking code. We need to figure out how to stop Marketo from removing the code.
November 26, 2013
Having the same issues here - would love to get some clarification on that.
December 2, 2013
Was there a solution to this issue as I am having the same troubles now.
December 2, 2013
No solutions yet! Sorry.
December 3, 2013
I went through this process with Litmus and was able to add its code to the HTML email template in Marketo's template section (under the Design tab). I remember there were some minor problems, but overall the code worked fine. If I remember correctly, the only Litmus option that was unavailable as a result was ability to track forwards and printing, or something minor to that extent.

I've raised this issue with Marketo on several occasions - please allow to turn off your wysiwyg on a per-user basis. They are completely uncooperative, stubborn, oblivious, and deaf to these requests. They believe they know better by forcing their wysiwyg to those who don't want it. 

On the other hand, Litmus support was absolutely fantastic in helping with this issue.

Good luck!