Skip to content

Commit 97e616f

Browse files
author
Saeid Darvish
authored
Merge pull request #54 from saeiddrv/draft
edited google-tag
2 parents aca4374 + b4e9493 commit 97e616f

File tree

1 file changed

+9
-13
lines changed
  • source/_templates/sphinx_minoo_theme/includes

1 file changed

+9
-13
lines changed

source/_templates/sphinx_minoo_theme/includes/header.html

Lines changed: 9 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -86,19 +86,15 @@
8686
{%- endfor %}
8787
{% endif %}
8888

89-
{% if theme_analytics_id %}
90-
<script type="text/javascript">
91-
var _gaq = _gaq || [];
92-
_gaq.push(['_setAccount', '{{ theme_analytics_id }}' ]);
93-
_gaq.push(['_trackPageview']);
94-
95-
(function() {
96-
var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
97-
ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
98-
var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
99-
})();
100-
</script>
101-
{% endif %}
89+
<!-- Google tag (gtag.js) -->
90+
<script async src="https://www.googletagmanager.com/gtag/js?id=G-25G1Z7B4EZ"></script>
91+
<script>
92+
window.dataLayer = window.dataLayer || [];
93+
function gtag(){dataLayer.push(arguments);}
94+
gtag('js', new Date());
95+
96+
gtag('config', 'G-25G1Z7B4EZ');
97+
</script>
10298

10399
<script type="text/javascript" src="{{ pathto('_static/minoo-20230401.js', 1) }}"></script>
104100
<script type="text/javascript" src="{{ pathto('_static/modernizr.min.js', 1) }}"></script>

0 commit comments

Comments
 (0)