User:Brookie/pagestats.js

if(wgNamespaceNumber>=0) (function{   var f=function{        var dt=new Date;        var y=dt.getFullYear;        var m=dt.getMonth;        if(m==0){ y--; m=12; }        if(m<10) m='0'+m;        mw.util.addPortletLink('p-tb', 'http://stats.grok.se/'+encodeURIComponent(wgContentLanguage)+'/'+y+''+m+'/'+encodeURIComponent(mw.config.get('wgPageName')), 'Page view stats', 't-pageviews');        mw.util.addPortletLink('p-tb', 'http://vs.aka-online.de/cgi-bin/wppagehiststat.pl?lang='+encodeURIComponent(wgContentLanguage)+'&page='+encodeURIComponent(mw.config.get('wgPageName')), 'Page edit stats', 't-editstats');        mw.util.addPortletLink('p-tb', 'http://toolserver.org/~dispenser/cgi-bin/readability1.2.py?family=wikipedia&lang='+encodeURIComponent(wgContentLanguage)+'&page='+encodeURIComponent(mw.config.get('wgPageName')), 'Page readability stats', 't-readability');        mw.util.addPortletLink('p-tb', 'http://tools.wikimedia.de/~dispenser/cgi-bin/webchecklinks.py?page='+encodeURIComponent(mw.config.get('wgPageName')), 'Check external links', 't-extlinks'); mw.util.addPortletLink('p-tb', 'http://toolserver.org/~mzmcbride/cgi-bin/watcher.py?db=enwiki_p&titles='+encodeURIComponent(mw.config.get('wgPageName')), 'Watcher count', 't-watchercount'); };

if(doneOnloadHook) f; //if imported dynamically else addOnloadHook(f); });