Google Tag Manager code not working

Hi

I have trouble getting Google Tag Manager to work on my marketplace (Sharetribe Go Open Source).

When using the Google Tag Assistant Chrome Extension I get the following message:
“GTM no-script code not found: either missing or not in body”

I went through Sharetribe’s installation instructions: https://help.sharetribe.com/articles/2529555-how-to-add-google-tag-manager-to-your-marketplace

Like the article said I put the code in the custom script section, like this:

Anyone who might have an idea of how I can solve this?

Hi there!

Hmm because you’re using the open-source version, you can configure GTM directly as an app config, at https://github.com/sharetribe/sharetribe/blob/master/config/config.defaults.yml#L201

Any reason why you prefer to do it via Custom Script?

Hi Thomas,

I have a freelance developer that is helping me with custom stuff for my marketplace every once in a while, I can’t do custom stuff on my own as of right now unfortunately so that’s why I wanted to try implementing GTM the easy way via Custom Script.

All right!

Well, that method (Custom Script) should work too so I’m not sure what’s wrong in your current setup.

Have you disabled all Analytics from the Analytics section in your admin panel, to avoid any conflict, if you add GTM via custom script?

Thanks for your reply!

In the Open Source version of Sharetribe Go there are no “Disable Sharetribe analytics” checkbox in the Analytics section of the admin panel. I haven’t put any tracking ID in the input field either.

My brother who manages the analytics says however that it seems like it’s working, so it’s strange that the Tag Assistant says that the GTM no-script code is missing because I presume GTM would not function at all without it.

Perhaps it’s just a bug with the Tag Assistant? My brother tells me the tag status in the Google Tag Assistant chrome extension should be green when it’s configured correctly, right now it’s blue but it seems to be working anyways.

Thanks for sharing the address.

Indeed, everything works great. Tags are triggered and if you receive some data and can use GTM’s preview mode smoothly, it’s all good.

You can also use the Google Analytics Debugger Chrome extension for more review of your Google Analytics events.

What the GTM assistant extension is complaining about is the non standard implementation. GTM would prefer the script to be added to the . However with Custom Script, it’s added to the .

That works fine, and there are ressources online that have proved it’s perfectly OK, but this is not the preferred setup from GTM’s point of view. This is why the extension says it’s not perfect, but works.

If you prefer to add it exactly as GTM is expecting, you can either add it manually to your body page code or, even better, ask your partner to use the app config variable :wink:

Hopefully this helps!

1 Like

Thank you very much for taking your time and confirming that it works, much appreciated!