add Piwik tracking to Lantea
authorRobert Kaiser <kairo@kairo.at>
Sun, 4 Dec 2016 18:27:05 +0000 (19:27 +0100)
committerRobert Kaiser <kairo@kairo.at>
Sun, 4 Dec 2016 18:27:05 +0000 (19:27 +0100)
index.html
js/piwik.js [new file with mode: 0644]

index 1a50ef742cff8168169d38d1e5f8a2e6f7f5a3a3..fd1dbe56974cc0e89bbf8f55fb161f44d110fa27 100644 (file)
   <script src="js/osmauth.js" type="application/javascript;version=1.8"></script>
   <script src="js/map.js" type="application/javascript;version=1.8"></script>
   <script src="js/ui.js" type="application/javascript;version=1.8"></script>
+  <script src="js/piwik.js" async="" defer=""></script>
   <link rel="stylesheet" href="style/lantea.css">
   <link rel="shortcut icon" href="style/lanteaIcon16.png" type="image/png">
 </head>
 <body id="body">
+<noscript><p><img src="https://piwik.kairo.at/piwik.php?idsite=2" style="border:0;" alt="" /></p></noscript>
 <h1>Lantea Map</h1>
 
 <div id="trackArea" class="menuDrawer hidden">
diff --git a/js/piwik.js b/js/piwik.js
new file mode 100644 (file)
index 0000000..19af876
--- /dev/null
@@ -0,0 +1,13 @@
+// Piwik code - licensed under Public Domain.
+  var _paq = _paq || [];
+  _paq.push(["setDomains", ["*.lantea.kairo.at","*.lantea-dev.kairo.at","*.lantea-legacy.kairo.at"]]);
+  _paq.push(['trackPageView']);
+  _paq.push(['enableLinkTracking']);
+  (function() {
+    var u="https://piwik.kairo.at/";
+    _paq.push(['setTrackerUrl', u+'piwik.php']);
+    _paq.push(['setSiteId', '2']);
+    var d=document, g=d.createElement('script'), s=d.getElementsByTagName('script')[0];
+    g.type='text/javascript'; g.async=true; g.defer=true; g.src=u+'piwik.js'; s.parentNode.insertBefore(g,s);
+  })();
+// End Piwik code