Difference between revisions of "MediaWiki:Common.js"

From LIFS LipidXplorer Wiki
Jump to navigation Jump to search
(Replaced content with " <!-- Matomo --> var _paq = window._paq = window._paq || []; →‎tracker methods like "setCustomDimension" should be called before "trackPageView": _paq.push(['tra...")
Tag: Replaced
Line 3: Line 3:
 
<!-- Matomo -->
 
<!-- Matomo -->
 
   var _paq = window._paq = window._paq || [];
 
   var _paq = window._paq = window._paq || [];
   /* tracker methods like "setCustomDimension" should be called before "trackPageView" */
+
   _paq.push(['requireConsent']);
 +
  _paq.push(['requireCookieConsent']);
 
   _paq.push(['trackPageView']);
 
   _paq.push(['trackPageView']);
 
   _paq.push(['enableLinkTracking']);
 
   _paq.push(['enableLinkTracking']);

Revision as of 07:53, 10 June 2021


<!-- Matomo -->
  var _paq = window._paq = window._paq || [];
  _paq.push(['requireConsent']);
  _paq.push(['requireCookieConsent']);
  _paq.push(['trackPageView']);
  _paq.push(['enableLinkTracking']);
  (function() {
    var u="https://lifs-tools.org/matomo/";
    _paq.push(['setTrackerUrl', u+'matomo.php']);
    _paq.push(['setSiteId', '7']);
    var d=document, g=d.createElement('script'), s=d.getElementsByTagName('script')[0];
    g.type='text/javascript'; g.async=true; g.src=u+'matomo.js'; s.parentNode.insertBefore(g,s);
  })();