Skip to content

Commit

Permalink
Merge pull request #503 from deNBI/feat/tracking
Browse files Browse the repository at this point in the history
fix(Tracking): Adjusted matomo script
  • Loading branch information
vktrrdk authored Jun 21, 2024
2 parents 451c5c4 + 1d78e12 commit 20181f5
Showing 1 changed file with 11 additions and 9 deletions.
20 changes: 11 additions & 9 deletions wiki/matomo.js
Original file line number Diff line number Diff line change
@@ -1,13 +1,15 @@
var _paq = window._paq || [];
var _paq = window._paq = window._paq || [];
/* tracker methods like "setCustomDimension" should be called before "trackPageView" */
_paq.push(['trackPageView']);
_paq.push(['enableLinkTracking']);
(function() {
var u="//cloud.denbi.de/matomo/";
_paq.push(['setTrackerUrl', u+'matomo.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+'matomo.js'; s.parentNode.insertBefore(g,s);
})();


var u = "https://piwik.cebitec.uni-bielefeld.de/";
_paq.push(['setTrackerUrl', u + 'matomo.php']);
_paq.push(['setSiteId', '22']);
var d = document,
g = d.createElement('script'),
s = d.getElementsByTagName('script')[0];
g.async = true;
g.src = u + 'matomo.js';
s.parentNode.insertBefore(g, s);
})();

0 comments on commit 20181f5

Please sign in to comment.