Jump to content

Error when pasting Google Analytics code


Go to solution Solved by Jim M,

Recommended Posts

Your GA code should look like:

<!-- Google tag (gtag.js) -->
<script async src="https://www.googletagmanager.com/gtag/js?id=G-XXXXXXXXX"></script>
<script>
  window.dataLayer = window.dataLayer || [];
  function gtag(){dataLayer.push(arguments);}
  gtag('js', new Date());

  gtag('config', 'G-XXXXXXXXX');
</script>

This code would be inserted into: 

ACP > System > Site Features > Integrations > Google Analytics

After adding the code, you MAY need to clear your system cache.  

ACP > System > Support > Get Support

Click on "Clear System Caches".

Link to comment
Share on other sites

I cleared my cache and then pasted again as per the above instructions- still  no good. 

 

<!-- Google tag (gtag.js) -->
<script async src="https://www.googletagmanager.com/gtag/js?id=UA-4567890-1"></script>
<script>
  window.dataLayer = window.dataLayer || [];
  function gtag(){dataLayer.push(arguments);}
  gtag('js', new Date());

  gtag('config', 'UA-567899-1');
</script>

Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...