How do I insert custom javascript into Customerhub pages?

I am trying to add Google Track Management javascript code to my Customerhub pages so that I can track the number of times a file is downloaded. There are two pieces of code. One goes in the tag of all Customerhub pages, and the other immediately after the tag on the pages where I am tracking the clicks of the download links. In Customerhub, I can add javascript using the Customize Theme tool, but the code is placed at the bottom of the tag. I can also add code on an individual page, however the code is placed inside the first

tag. Both the wrong location. Does anyone know how I can control where my code is added in the page’s code?

Thanks in Advance.

When adding code to a page inside of Customerhub clicking the “<>” icon will allow you to add custom code into the body of the page. The body is the place that custom code can be added. Which tag are you referring to?

I am trying to add tracking code for Google Tag Management. It requires two pieces of code. One inside the tag and the other immediately after the opening tag. The <> icon places code at the bottom of the body section just before the closing tag.

Google tag management requires code in both the header and body tags from what I remember.

1 Like