Jump to content

1.5.5.0 Where Google Analytic code is stored ?


Recommended Posts

Hello,

 

Can anyone advise where can I see Google Analytics code is stored ?

 

I’ve already updated GA id though Google Analytics module but I just want to recheck. Because for some dubious reasons Google is unable to produce tracking results.

 

Thanks in advance.

 

Fred

Link to comment
Share on other sites

Hi Fred,

 

I checked page source and found ga code. It shows:

 

</script>
<script type="text/javascript">
var _gaq = _gaq || [];
_gaq.push(['_setAccount', 'UA-12345-1']);
// Recommanded value by Google doc and has to before the trackPageView
_gaq.push(['_setSiteSpeedSampleRate', 5]);
_gaq.push(['_trackPageview']);
(function() {
var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
})(); 
</script>
 
But in GA Property Settings --> Tracking info --> Tracking code, i see below:
 
<script>
  (function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
  (i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
  m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
  })(window,document,'script','//www.google-analytics.com/analytics.js','ga');
 
  ga('create', 'UA-12345-1', 'example.com');
  ga('send', 'pageview');
 
</script>
 
Do you think is there anything wrong with the code generated through GA module ?
 
Thanks again.
 
Fred
Link to comment
Share on other sites

×
×
  • Create New...