From 8f51c5a43d864ad91f40f8bae764d61315a48b41 Mon Sep 17 00:00:00 2001 From: Paul Hayes Date: Thu, 14 May 2015 15:06:26 +0100 Subject: [PATCH 1/2] Remove classic analytics --- _includes/layouts/_body.html | 3 +-- service-manual/assets/javascript/analytics-init.js | 9 ++++----- 2 files changed, 5 insertions(+), 7 deletions(-) diff --git a/_includes/layouts/_body.html b/_includes/layouts/_body.html index 6cbeb964..83417ba5 100644 --- a/_includes/layouts/_body.html +++ b/_includes/layouts/_body.html @@ -1,9 +1,8 @@ - - + diff --git a/service-manual/assets/javascript/analytics-init.js b/service-manual/assets/javascript/analytics-init.js index 35166fd2..45a3bf28 100644 --- a/service-manual/assets/javascript/analytics-init.js +++ b/service-manual/assets/javascript/analytics-init.js @@ -1,17 +1,16 @@ (function() { "use strict"; - GOVUK.Tracker.load(); + GOVUK.Analytics.load(); var cookieDomain = (document.domain === 'www.gov.uk') ? '.www.gov.uk' : document.domain; - GOVUK.analytics = new GOVUK.Tracker({ - universalId: 'UA-26179049-7', - classicId: 'UA-26179049-1', + GOVUK.analytics = new GOVUK.Analytics({ + universalId: 'UA-26179049-1', cookieDomain: cookieDomain }); if (window.devicePixelRatio) { - GOVUK.analytics.setDimension(11, window.devicePixelRatio, 'Pixel Ratio', 2); + GOVUK.analytics.setDimension(11, window.devicePixelRatio); } GOVUK.analytics.trackPageview(); From 7d3a9f186d2319ac84a767e0bcee962372e1b459 Mon Sep 17 00:00:00 2001 From: Paul Hayes Date: Tue, 26 May 2015 16:09:55 +0100 Subject: [PATCH 2/2] Update frontend_toolkit to 4.0.0 Pull in latest analytics changes which remove Google Analytics classic. (Run `git pull origin master` within toolkit directory) --- service-manual/assets/toolkit | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/service-manual/assets/toolkit b/service-manual/assets/toolkit index 5199b77e..6f9febc4 160000 --- a/service-manual/assets/toolkit +++ b/service-manual/assets/toolkit @@ -1 +1 @@ -Subproject commit 5199b77ee98f74c9815725ba8aafdbad699bc6df +Subproject commit 6f9febc4204f0ffbf83738c0c65af55f5f795faa