1 / 4
Sep 2012

I recently successfully implemented the e-junkie version of the Google Analytics tracking code and it has been working correctly to allow us to track conversions properly. Unfortunately, at the same time, it appears to have broken our ability to track our AdSense data in Analytics.



I did a little research and found this Google help article on the subject: http://support.google.com/adsense/bin/answer.py?hl=en&answer=99906



It seems like it might discuss the problem, which apparently is that tracking code making use of the "SetDomainName" function needs to have another variable set on the page for Analytics to properly track AdSense. Their suggestion is to insert: google_analytics_domain_name="example.com"; before the AdSense code, where "example.com" is the domain that is referenced in the SetDomainName function.



But in the e-junkie SetDomainName function, the domain is "none" as in: ejGATracker._setDomainName("none");



Since that doesn't appear to be the actual Google SetDomainName function, but something specifically implemented by e-Junkie, I'm a little hesitant to try google_analytics_domain_name="none"; for fear that Google won't understand it.



Does anyone have any insight on what is happening here and whether or not it's safe to try the Google solution with the e-junkie code? Or am I barking up the wrong tree entirely, and the AdSense problem is unrelated to this?



Thanks!



Scott

  • created

    Sep '12
  • last reply

    Sep '12
  • 3

    replies

  • 1.5k

    views

  • 2

    users

  • 1

    link

From what I can tell, AdSense Analytics code is distinct from regular Google Analytics tracking code, so just follow their guidelines as to what AdSense code should be added to the page and where it should be placed in the page relative to any Google Analytics code that's also in the same page.

Just in case anyone else runs into this problem, I can report that adding 'google_analytics_domain_name="none";' as indicated in the Google troubleshooting article DOES restore AdSense code to Analytics while using the custom e-junkie Analytics code.



Cheers,



Scott

Except now my conversions are no longer registering in Analytics. Help! Any idea why this addition would have broken the conversion tracking code?