Analytics pageview on navigation

This commit is contained in:
Kasper Rynning-Tønnesen
2018-01-23 15:15:43 +01:00
parent 79eb814677
commit bf395b061f
3 changed files with 3 additions and 1 deletions

View File

@@ -386,6 +386,7 @@ function initfp() {
//Materialize.toast('<p id="aprilfools">We suck at pranks..<a class="waves-effect waves-light btn light-green" style="pointer-events:none;">Agreed</a></p>', 100000); //Materialize.toast('<p id="aprilfools">We suck at pranks..<a class="waves-effect waves-light btn light-green" style="pointer-events:none;">Agreed</a></p>', 100000);
} }
ga('send', 'pageview');
window.onpopstate = function(e){ window.onpopstate = function(e){
var url_split = window.location.href.split("/"); var url_split = window.location.href.split("/");

View File

@@ -200,6 +200,8 @@ function init(){
mobile_beginning = Helper.mobilecheck(); mobile_beginning = Helper.mobilecheck();
var side = Helper.mobilecheck() ? "left" : "right"; var side = Helper.mobilecheck() ? "left" : "right";
ga('send', 'pageview');
window.onpopstate = function(e){ window.onpopstate = function(e){
onepage_load(); onepage_load();
}; };

View File

@@ -40,7 +40,6 @@
})(window,document,'script','//www.google-analytics.com/analytics.js','ga'); })(window,document,'script','//www.google-analytics.com/analytics.js','ga');
ga('create', '***REMOVED***', 'auto'); ga('create', '***REMOVED***', 'auto');
ga('send', 'pageview');
</script> </script>
<script type="text/javascript" src="https://code.jquery.com/jquery-2.2.4.min.js"></script> <script type="text/javascript" src="https://code.jquery.com/jquery-2.2.4.min.js"></script>
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/materialize/0.100.2/js/materialize.min.js"></script> <script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/materialize/0.100.2/js/materialize.min.js"></script>