跳转到内容

User:NigelSoft/common.js

维基百科,自由的百科全书

这是本页的一个历史版本,由NigelSoft留言 | 贡献2014年7月17日 (四) 10:55编辑。这可能和当前版本存在着巨大的差异。

注意:保存之后,你必须清除浏览器缓存才能看到做出的更改。Google ChromeFirefoxMicrosoft EdgeSafari:按住⇧ Shift键并单击工具栏的“刷新”按钮。参阅Help:绕过浏览器缓存以获取更多帮助。
if (window.location.protocol=="http:"){window.location="https://"+location.hostname+location.pathname+location.search+location.hash}

importScript('User:NigelSoft-Library/Scripts/CSTLiveClock.js');
mw.loader.load('//meta.wikimedia.org/w/index.php?title=User:Hedonil/XTools/XTools.js&action=raw&ctype=text/javascript');
importScript('User:Isnow/CategoryPageForm.js');

mw.util.addPortletLink(
 'p-personal',
 '/wiki/User:NigelSoft/Tools/Sandboxes',
 '我的沙盒',
 'pt-mysandbox',
 '我的沙盒',
 null,
 '#pt-preferences'
 );

mw.util.addPortletLink(
 'p-personal',
 '/w/index.php?title=Special:最新页面&hidepatrolled=1&hidebots=1',
 '新页面巡查',
 'pt-newpagespatrol',
 '新页面巡查',
 null,
 '#pt-preferences'
 );

importScript('User:PhiLiP/wikicache/load.js');
importScript('User:Bencmq/Mass rollback.js');
mw.loader.load('//www.mediawiki.org/w/index.php?title=MediaWiki:Gadget-DotsSyntaxHighlighter.js&action=raw&ctype=application/javascript&smaxage=21600&maxage=86400');
mw.loader.load('//de.wikipedia.org/w/index.php?title=Benutzer:TMg/autoFormatter.js&action=raw&ctype=text/javascript');
mw.loader.load('//de.wikipedia.org/w/index.php?title=Benutzer:TMg/cleanDiff.js&action=raw&ctype=text/javascript');

addOnloadHook(function () {
    var hist; var url;
    if (!(hist = document.getElementById('ca-history') )) return;
    if (!(url = hist.getElementsByTagName('a')[0] )) return;
    if (!(url = url.href )) return;
    addPortletLink('p-cactions', url.replace(/([?&]action=)history([&#]|$)/, '$1purge$2'),
                   wgULS('清除缓存'), 'ca-purge', wgULS('更新服务器缓存'), '*');
 
});