Welcome to WebmasterWorld Guest from 52.87.253.202

Forum Moderators: DixonJones & mademetop

Message Too Old, No Replies

GA and new added line like Google Tag manager

     
9:13 pm on Dec 2, 2017 (gmt 0)

Senior Member

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month

joined:Oct 25, 2006
posts: 1088
votes: 1


I have seen new added line inside GA which is used also to integrate Google Tag Manager.

As Google Tag Manager has its own tracking code is this needed to integrate GA and Google Tag Manage or it is not needed as both have other tracking code?

I'm not sure but why is then added line inside GA like <script async src="https://www.googletagmanager.com/gtag/js?id="></script>

Example: We track GA and Google Tag Manager using separate tracking code like suggested but than there is added new line inside GA.

I'm new to this and need help.
1:40 am on Dec 4, 2017 (gmt 0)

Moderator

WebmasterWorld Administrator ergophobe is a WebmasterWorld Top Contributor of All Time 10+ Year Member Top Contributors Of The Month

joined:Apr 25, 2002
posts:8627
votes: 274


Google recently rolled out an update to their tracking system.

The old script, was the Universal Analytics analytics.js. The new one is the gtag.js script. For the time being at least, they record the same data, though the methods of doing so are different.

In any case, you should not have an *added* line. If you have gtag.js, you should therefore no longer have analytics. js. It's one or the other.

Also, your gtag call doesn't define an account ID, so it isn't sending any data anyway.

I think your best bet is just to start over. Get rid of your Google Analytics tag and implement it anew, using whichever version you prefer, but definitely using only one version or the other, with a proper account ID declared.

See
- "Migrate from analytics.js to gtag.js" - [developers.google.com...]
- "Add gtag.js to your site" - [developers.google.com...]
- "Set up analytics tracking with gtag.js" - [support.google.com...]
12:06 pm on Dec 5, 2017 (gmt 0)

Senior Member

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month

joined:Oct 25, 2006
posts: 1088
votes: 1


Thank you for this information. Strange that it is an article from October and I added new account two days ago with the old code without any marked area for gtag.js
3:12 am on Dec 28, 2017 (gmt 0)

Senior Member from US 

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month

joined:May 29, 2007
posts: 896
votes: 144


They tell you to add this new code immediately after the <head> in the site.

Can the code go after this instead: <head>
<meta charset="UTF-8">
CODE HERE
10:44 pm on Dec 29, 2017 (gmt 0)

Senior Member from US 

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month

joined:May 29, 2007
posts: 896
votes: 144


I answered my own question. I put the jtag.js farther down in the head section, and it works well.
 

Join The Conversation

Moderators and Top Contributors

Hot Threads This Week

Featured Threads

Free SEO Tools

Hire Expert Members