Updated Google Analytics code (#123)
GA site tag was updated today, misc.html has been changed to reflect the same.
This commit is contained in:
parent
a734d4a4bc
commit
c085a63ca6
@ -6,15 +6,14 @@ $(function () {$('[data-toggle="tooltip"]').tooltip()})
|
|||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
{% if site.enable_google_analytics %}
|
{% if site.enable_google_analytics %}
|
||||||
<!-- Google Analytics -->
|
<!-- Global site tag (gtag.js) - Google Analytics -->
|
||||||
|
<script async src="https://www.googletagmanager.com/gtag/js?id={{ site.google_analytics }}"></script>
|
||||||
<script>
|
<script>
|
||||||
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
|
window.dataLayer = window.dataLayer || [];
|
||||||
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
|
function gtag() { dataLayer.push(arguments); }
|
||||||
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
|
gtag('js', new Date());
|
||||||
})(window,document,'script','//www.google-analytics.com/analytics.js','ga');
|
|
||||||
|
|
||||||
ga('create', '{{ site.google_analytics }}', 'auto');
|
gtag('config', '{{ site.google_analytics }}');
|
||||||
ga('send', 'pageview');
|
|
||||||
</script>
|
</script>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user