Welcome to the in5 Answer Exchange! This a place to get answers about in5 (InDesign to HTML5) and make requests.
0 votes

I have an interactive chart that is within my clients site and when I add the google analytics coding they are requesting it breaks the entire thing. It worked in the past but with this latest version of the site it does not. 

I am not a coder by any means, but I know I have the information in the right spot of the HTML code so I am not sure what is happening. I am using version 3.8.24 with InDesign 2026.

This is the page without the Google Analytics: https://www.victaulic.com/interactive-sprinkler-chart/

And here is their instruction on how to put the code for the analytics.
 

1. Paste this code as high in the <head> of the page as possible:

 

<!-- Google Tag Manager -->

<script>(function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'gtm.start':

new Date().getTime(),event:'gtm.js'});var f=d.getElementsByTagName(s)[0],

j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src=

})(window,document,'script','dataLayer','GTM-W22DGC');</script>

<!-- End Google Tag Manager -->

 

2. Paste this code immediately after the opening <body> tag:

 

<!-- Google Tag Manager (noscript) -->

height="0" width="0" style="display:none;visibility:hidden"></iframe></noscript>

Is there something that changed in the more recent updates to make this not work as it did previously?

ago in bugs by (140 points)
  

1 Answer

0 votes
Thanks for reaching out! The latest version of in5 is version 3.8.25. You can download it here. Support for Google Analytics is built into in5. Google Analytics is widely regarded as the industry standard (and it's free), that's why it is the only built-in option at this time. 
To use another analytics platform, you would need to add custom JavaScript. If you aren't working with a web developer, then we would recommend contracting one to create this custom JavaScript for you. If you don't know of a web developer, we can recommend one for you.
The good news is that you only have to figure the code out once, and your JavaScript files can be re-used and attached to any in5 export.
I hope this helps!
ago by (260 points)