Toggle menu
Toggle preferences menu
Toggle personal menu
Not logged in
Your IP address will be publicly visible if you make any edits.

MediaWiki:Common.js: Difference between revisions

MediaWiki interface page
No edit summary
No edit summary
Line 1: Line 1:
/* Any JavaScript here will be loaded for all users on every page load. */
/* Any JavaScript here will be loaded for all users on every page load. */
<!-- Google tag (gtag.js) -->
/* Google Analytics GA4 */
<script async src="https://www.googletagmanager.com/gtag/js?id=G-C5TG4DYGL8"></script>
var gaScript = document.createElement('script');
<script>
gaScript.async = true;
  window.dataLayer = window.dataLayer || [];
gaScript.src = "https://www.googletagmanager.com/gtag/js?id=G-C5TG4DYGL8";
  function gtag(){dataLayer.push(arguments);}
document.head.appendChild(gaScript);
  gtag('js', new Date());


  gtag('config', 'G-C5TG4DYGL8');
window.dataLayer = window.dataLayer || [];
</script>
function gtag(){ dataLayer.push(arguments); }
<script async src="https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js?client=ca-pub-6165763582752350" crossorigin="anonymous"></script>
gtag('js', new Date());
gtag('config', 'G-C5TG4DYGL8');
 
/* Google AdSense */
var adsense = document.createElement('script');
adsense.async = true;
adsense.src = "https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js?client=ca-pub-6165763582752350";
adsense.setAttribute("crossorigin", "anonymous");
document.head.appendChild(adsense);

Revision as of 10:09, 19 January 2026

/* Any JavaScript here will be loaded for all users on every page load. */
/* Google Analytics GA4 */
var gaScript = document.createElement('script');
gaScript.async = true;
gaScript.src = "https://www.googletagmanager.com/gtag/js?id=G-C5TG4DYGL8";
document.head.appendChild(gaScript);

window.dataLayer = window.dataLayer || [];
function gtag(){ dataLayer.push(arguments); }
gtag('js', new Date());
gtag('config', 'G-C5TG4DYGL8');

/* Google AdSense */
var adsense = document.createElement('script');
adsense.async = true;
adsense.src = "https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js?client=ca-pub-6165763582752350";
adsense.setAttribute("crossorigin", "anonymous");
document.head.appendChild(adsense);