Analytics
3.9K members online now
3.9K members online now
Dive into multiple domain (Cross/Sub) tracking, implementing Ecommerce and Enhanced Ecommerce, setting up Event tracking, and Universal Analytics code.
 
Guide Me
star_border
Reply

Google tag manager | Crashing My WP Site - Why?

Visitor ✭ ✭ ✭
# 1
Visitor ✭ ✭ ✭

Hi can anyone advise please? 

 

I am trying to install GA Tag Container code on my WP site but every time I do the site crashes (and has to be reloaded from the server archive). The site is: www.sparks4growth.com

 

Is anyone able to advise/have a look for me? 

 

Many thanks happy to email or Skype about it: mark@sparks4growth.com

Mark 

 

1 Expert replyverified_user

Re: Google tag manager | Crashing My WP Site - Why?

Explorer ✭ ✭ ☆
# 2
Explorer ✭ ✭ ☆
Hi Mark,

Where are you adding the GTM tag? It should, ideally, be immediately after the opening <body> tag. But it can be placed lower on the page if this causes any issue. The tag willl fire on the page slightly late based on how far down the GTM tag is on the page.

Re: Google tag manager | Crashing My WP Site - Why?

[ Edited ]
Visitor ✭ ✭ ✭
# 3
Visitor ✭ ✭ ✭

Hi Syed, thanks for your reply

That's where I placed it. But the site locked up, crashed and then I couldn't anything at all (so had to load archive of site).


Mark E

<edited by a Community Manager as noted below>
Note: this post has been edited by a Community Manager, per Community Guidelines, in order to remove account specifics and/or personal contact information. This is done to protect account security and privacy.
Marked as Best Answer.
Solution
Accepted by topic author Mark E
May 2016

Re: Google tag manager | Crashing My WP Site - Why?

[ Edited ]
Rising Star
# 4
Rising Star

Are you editing the template directly, and if so, are you ftp'ing into the server or editing it via the theme editor in WordPress? There is nothing in GTM that should cause a lockup.

Instead of editing your template, try using the Header and Footer plugin (https://wordpress.org/plugins/header-footer/) and add GTM in the head for testing purposes (for those concerning with orthodoxy, please read http://www.simoahava.com/gtm-tips/gtm-container-snippet-in-the-head/#gref).

_________________________________________________________________________
Director of Marketing | Nehmedia | Partner Profile

Re: Google tag manager | Crashing My WP Site - Why?

Visitor ✭ ✭ ✭
# 5
Visitor ✭ ✭ ✭
Hi Phil,

Many thanks. I was editing the Template directly (and following Googles' advice on container location). I uninstalled the Yoast plug-in this time before adding the code snipper and that, along with the Header and Footer plug in seems to have cracked it.

Much appreciated! Thanks, Mark