User:Microchip08/monobook.js

From Wikinews, the free news source you can write!
Jump to navigation Jump to search

Note: After saving, you may have to bypass your browser's cache to see the changes. Mozilla / Firefox / Safari: hold down Shift while clicking Reload, or press Ctrl-Shift-R (Cmd-Shift-R on Apple Mac); IE: hold Ctrl while clicking Refresh, or press Ctrl-F5; Konqueror: simply click the Reload button, or press F5; Opera users may need to completely clear their cache in Tools→Preferences. — More skins

mw.loader.load('https://simple.wikipedia.org/w/index.php?title=User:Microchip08/welcomer.js&action=raw&ctype=text/javascript');
mw.loader.load('https://simple.wikipedia.org/w/index.php?title=User:Microchip08/pgarequirements.js&action=raw&ctype=text/javascript');
mw.loader.load('https://simple.wikipedia.org/w/index.php?title=User:Microchip08/usernamehighlight.js&action=raw&ctype=text/javascript');
mw.loader.load('https://simple.wikipedia.org/w/index.php?title=User:Microchip08/talkblinker.js&action=raw&ctype=text/javascript');
mw.loader.load('https://simple.wikipedia.org/w/index.php?title=User:Microchip08/histcomb.js&action=raw&ctype=text/javascript');
mw.loader.load('https://simple.wikipedia.org/w/index.php?title=User:Microchip08/preview.js&action=raw&ctype=text/javascript');

mw.loader.load('https://simple.wikipedia.org/w/index.php?title=User:Bsadowski1/sysopdetector.js?action=raw&ctype=text/javascript');
// firefox extension without the firefox! woo!
var finderfoxConfig = {
    version: "1.0.0",
    key: "f74a34a8a6152e2300000123be100170"
};

mw.util.addPortletLink("p-tb", "http://stats.grok.se/en.n/"+ d.getUTCFullYear() + m +"/" + wgPageName, "Page popularity", "t-stats");});

function rot (str) {
    return (str+'').replace(/[a-z]/gi, function(s){
        return String.fromCharCode(s.charCodeAt(0)+(s.toLowerCase()<'n'?13:-13));
    });
}

function summarise( summary, minor ) {
    var sum = document.getElementById( "wpSummary" );
    if( sum.value != "" && sum.value.charAt( sum.value.length - 2 ) != "/" ) {
        sum.value += ', ' + summary;
    } else {
        sum.value += summary;
    }
    if( sendOnSummary == "preview" ) {
        document.getElementById("wpPreview").click();
    } else if( sendOnSummary == "save" ) {
        document.getElementById("wpSave").click();
    }
}

importScript('user:Bawolff/mwapilib2.js'); // just in case, yo
$(function () {
if ( document.getElementById("editform") != null) {
mw.util.addPortletLink('p-tb', 'javascript:summarise(rot(prompt("Enter a string")));', 'Swedify', 't-rot', 'Convert the edit summary to Swedish');
}});