Skip to content

Commit 85c5e60

Browse files
Remove ga-tag since it's moved to en.html and inheritance will follow. (travis-ci#3366)
* Remove ga-tag since it's moved to `en.html` and inheritance will follow. * Readd GTM tag that's GA4 compatible. It's Ruby based so it's inherited by all other pages. * Since Ruby Based, Make sure it it's inside head tag so it's inherited. * Inheritance via Ruby based and should inherit to `head.html` * add new GTM tag, Ruby inheritance for all pages * ga-tag update, inheritance from Ruby pages using via Jekyll * GTM for en_enterprise.html adding GTM tags into docs site also for enterprsie docs pages layout * GTM added to nodocs.html * GTM tag to 404.html adding as per PDTQ-131 - GTM * Ticket no comment added to en.html Just to have clear info --------- Co-authored-by: Michał Rybiński <[email protected]>
1 parent 8f6930e commit 85c5e60

File tree

5 files changed

+55
-13
lines changed

5 files changed

+55
-13
lines changed

404.html

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,14 @@
33
<!DOCTYPE HTML>
44
<html lang="en">
55
<head>
6+
<!-- PDTQ-131 -->
7+
<!-- Google Tag Manager -->
8+
<script>(function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'gtm.start':
9+
new Date().getTime(),event:'gtm.js'});var f=d.getElementsByTagName(s)[0],
10+
j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src=
11+
'https://www.googletagmanager.com/gtm.js?id='+i+dl;f.parentNode.insertBefore(j,f);
12+
})(window,document,'script','dataLayer','GTM-N3RT7TD');</script>
13+
<!-- End Google Tag Manager -->
614
<meta charset="utf-8">
715
<meta name="viewport" content="width=device-width, initial-scale=1">
816
<title>Travis CI Documentation - 404 Page not found</title>
@@ -216,6 +224,11 @@
216224
</script>
217225
</head>
218226
<body>
227+
<!-- PDTQ-131 -->
228+
<!-- Google Tag Manager (noscript) -->
229+
<noscript><iframe src="https://www.googletagmanager.com/ns.html?id=GTM-N3RT7TD"
230+
height="0" width="0" style="display:none;visibility:hidden"></iframe></noscript>
231+
<!-- End Google Tag Manager (noscript) -->
219232
<div class="error error404">
220233
<header class="top">
221234
<div class="row topbar">

_includes/head.html

Lines changed: 1 addition & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -23,16 +23,4 @@
2323

2424
{% for tag in page.swiftypetags %}
2525
<meta class="swiftype" name="tags" data-type="string" content="{{tag}}" />
26-
{% endfor %}
27-
28-
<script type="text/javascript">
29-
var _gaq = _gaq || [];
30-
_gaq.push(['_setAccount', 'UA-24868285-6']);
31-
_gaq.push(['_trackPageview']);
32-
33-
(function() {
34-
var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
35-
ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
36-
var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
37-
})();
38-
</script>
26+
{% endfor %}

_layouts/en.html

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,24 @@
11
<!DOCTYPE HTML>
22
<html lang="en">
33
<head>
4+
<!-- PDTQ-131 -->
5+
<!-- Google Tag Manager -->
6+
<script>(function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'gtm.start':
7+
new Date().getTime(),event:'gtm.js'});var f=d.getElementsByTagName(s)[0],
8+
j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src=
9+
'https://www.googletagmanager.com/gtm.js?id='+i+dl;f.parentNode.insertBefore(j,f);
10+
})(window,document,'script','dataLayer','GTM-N3RT7TD');</script>
11+
<!-- End Google Tag Manager -->
12+
413
{% include head.html %}
514
</head>
615
<body>
16+
<!-- PDTQ-131 -->
17+
<!-- Google Tag Manager (noscript) -->
18+
<noscript><iframe src="https://www.googletagmanager.com/ns.html?id=GTM-N3RT7TD"
19+
height="0" width="0" style="display:none;visibility:hidden"></iframe></noscript>
20+
<!-- End Google Tag Manager (noscript) -->
21+
722
<div class="wrapper">
823

924
{% include header.html %}

_layouts/en_enterprise.html

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,22 @@
11
<!DOCTYPE HTML>
22
<html lang="en">
33
<head>
4+
<!-- PDTQ-131 -->
5+
<!-- Google Tag Manager -->
6+
<script>(function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'gtm.start':
7+
new Date().getTime(),event:'gtm.js'});var f=d.getElementsByTagName(s)[0],
8+
j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src=
9+
'https://www.googletagmanager.com/gtm.js?id='+i+dl;f.parentNode.insertBefore(j,f);
10+
})(window,document,'script','dataLayer','GTM-N3RT7TD');</script>
11+
<!-- End Google Tag Manager -->
412
{% include head.html %}
513
</head>
614
<body class="enterprise">
15+
<!-- PDTQ-131 -->
16+
<!-- Google Tag Manager (noscript) -->
17+
<noscript><iframe src="https://www.googletagmanager.com/ns.html?id=GTM-N3RT7TD"
18+
height="0" width="0" style="display:none;visibility:hidden"></iframe></noscript>
19+
<!-- End Google Tag Manager (noscript) -->
720
<div class="wrapper">
821

922
{% include header.html %}

_layouts/nodocs.html

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,22 @@
11
<!DOCTYPE HTML>
22
<html lang="en">
33
<head>
4+
<!-- PDTQ-131 -->
5+
<!-- Google Tag Manager -->
6+
<script>(function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'gtm.start':
7+
new Date().getTime(),event:'gtm.js'});var f=d.getElementsByTagName(s)[0],
8+
j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src=
9+
'https://www.googletagmanager.com/gtm.js?id='+i+dl;f.parentNode.insertBefore(j,f);
10+
})(window,document,'script','dataLayer','GTM-N3RT7TD');</script>
11+
<!-- End Google Tag Manager -->
412
{% include head.html %}
513
</head>
614
<body>
15+
<!-- PDTQ-131 -->
16+
<!-- Google Tag Manager (noscript) -->
17+
<noscript><iframe src="https://www.googletagmanager.com/ns.html?id=GTM-N3RT7TD"
18+
height="0" width="0" style="display:none;visibility:hidden"></iframe></noscript>
19+
<!-- End Google Tag Manager (noscript) -->
720
<div class="nodocs">
821

922
{% include header.html %}

0 commit comments

Comments
 (0)