User:Saph668/common.js
Note: You may have to bypass your browser’s cache to see the changes. In addition, after saving a sitewide CSS file such as MediaWiki:Common.css, it will take 5-10 minutes before the changes take effect, even if you clear your cache.
- Mozilla / Firefox / Safari: hold Shift while clicking Reload, or press either Ctrl-F5 or Ctrl-R (Command-R on a Macintosh);
- Konqueror and Chrome: click Reload or press F5;
- Opera: clear the cache in Tools → Preferences;
- Internet Explorer: hold Ctrl while clicking Refresh, or press Ctrl-F5.
- This script lacks a documentation subpage. You may create it.
- Useful links: root page • root page’s subpages • links • redirects • your own
This JavaScript is executed for Saph668 on every page load.
importScript('User:Erutuon/addAutoCat.js');
// Add WikiBlame launcher to the Tools menu
$(function () {
mw.util.addPortletLink(
"p-tb", // toolbox portlet
"http://ramselehof.de/wikipedia/wikiblame.php?user_lang=en&lang=" + mw.config.get('wgContentLanguage')
+ "&project=wikipedia&article=" + mw.config.get('wgPageName')
+ "&needle=&skipversions=0&ignorefirst=0&limit=500&searchmethod=int&order=desc&user=",
"WikiBlame" // link label
)});
mw.loader.load('https://meta.wikimedia.org/w/index.php?title=User:Jack who built the house/editHere.js&action=raw&ctype=text/javascript');
jQuery(document).ready(function ($) {
console.log("executing common.js");
try {
importScript("User:Erutuon/scripts/cleanup.js");
importScript("User:Erutuon/scripts/addAutoCat.js");
importScript("User:Erutuon/scripts/phonemicGreekTransliteration.js");
importScript("User:Fenakhay/scripts/nonmainspaceCategories.js");
importScript("User:Erutuon/scripts/gadgets-definition.js");
importScript("User:Fenakhay/extraCategoryLinks.js");
importScript("User:Ioaxxere/minitoc.js");
importScript("User:Ioaxxere/webapp.js");
/********* quick move revert *********/
$('.mw-logline-move a[href*="wpReason=revert"]').each(function () {
if (this.href.indexOf('&autosubmitmove=1') < 0)
this.href += '&wpLeaveRedirect=0&autosubmitmove=1';
});
if (mw.config.get("wgPageName").startsWith("Special:MovePage") && new URL(window.location.href).searchParams.get("autosubmitmove") == '1') {
$('button[name="wpMove"]').click();
}
} catch (e) {
console.error(e);
}
mw.hook("wikipage.content").add(function () { console.log("wikipage.content hook"); });
console.log("executed common.js");
});