User:SpacemanSpiff/common.js
Appearance
Code that you insert on this page could contain malicious content capable of compromising your account. If you import a script from another page with "importScript", "mw.loader.load", "iusc", or "lusc", take note that this causes you to dynamically load a remote script, which could be changed by others. Editors are responsible for all edits and actions they perform, including by scripts. User scripts are not centrally supported and may malfunction or become inoperable due to software changes. A guide to help you find broken scripts is available. If you are unsure whether code you are adding to this page is safe, you can ask at the appropriate village pump. This code will be executed when previewing this page. |
The accompanying .css page for this skin is at User:SpacemanSpiff/common.css. |
// AfD
// importScript('User:Evad37/XFDcloser.js'); // [[User:Evad37/XFDcloser]]
// importScript('User:Mr.Z-man/closeAFD.js');
// Yet another AfC helper script v4. activate when needed
//importScript('User:Timotheus Canens/afchelper4.js');
//[[User:Ucucha/HarvErrors]], activate when needed
//importScript('User:Ucucha/HarvErrors.js');
//[[User:Animum/easyblock.js]]
importScript('User:Animum/easyblock.js');
// [[User:NuclearWarfare/Mark-blocked script.js]]
importScript('User:NuclearWarfare/Mark-blocked script.js');
// Deletion sorting script [[WP:FWDS]]
importScript('User:Fox Wilson/delsort-monobook.js');
window.addEventListener('load', function(){
defineLink("India");
defineLink("Cricket");
}, false);
//[[User:Ale_jrb/Scripts]]
importScript('User:Ale_jrb/Scripts/csdhelper.js');
//[[User:Ale_jrb/Scripts]]
importScript('User:Ale_jrb/Scripts/csdcheck.js');
//Mass rollback function
//Written by John254 and modified/rewritten by Writ Keeper; original is at https://wiki.riteme.site/wiki/User:John254/mass_rollback.js
//Adapted from User:Mr.Z-man/rollbackSummary.js
//Instructions: Selecting the "rollback all" tab when viewing a user's contributions history
//will open all rollback links displayed there. (Use with caution)
function rollbackEverythingWKMR()
{
var userName = /Contributions\/(.+)/.exec(mw.config.get("wgTitle"))[1];
var tokenRegex = /token=([^&]+)/;
var titleRegex = /title=([^&]+)/;
$("a[href*='action=rollback']").each(function(ind, el)
{
var regexResults = tokenRegex.exec(el.href);
rollbackToken = decodeURIComponent(regexResults[1]);
var postInfo = {action:"rollback",title:titleRegex.exec(el.href)[1],token:rollbackToken,user:userName};
$.post("/w/api.php", postInfo, function()
{
$(el).after("reverted");
$(el).remove();
});
});
}
$(document).ready(function()
{
if(mw.config.get("wgCanonicalSpecialPageName") == "Contributions" && $("span.mw-rollback-link").length > 0)
{
mw.util.addPortletLink('p-cactions', 'javascript:rollbackEverythingWKMR()', "rollback all", "ca-rollbackeverything", "rollback all edits displayed here");
$("#ca-rollbackeverything").click(function(){return confirm("Really rollback *everything*?")});
}
});
//Other
//importScript('User:Ale_jrb/Scripts/statusCheck.js'); //Online or not for users
importScript('User:Ale_jrb/Scripts/userhist.js');
importScript('User:Plastikspork/admindash.js');
//importScript('Wikipedia:WikiProject User scripts/Scripts/Force edit summary alternative');
/* User:קיפודנחש/cat-a-lot.js */
importScript( 'User:קיפודנחש/cat-a-lot.js' );// Backlink: [[User:קיפודנחש/cat-a-lot.js]]
/* User:MusikAnimal/responseHelper.js */
importScript( 'User:MusikAnimal/responseHelper.js' );// Backlink: [[User:MusikAnimal/responseHelper.js]]
/* User:Technical_13/Scripts/OneClickArchiver */
importScript( 'User:Technical_13/Scripts/OneClickArchiver.js' );// Backlink: [[User:Technical_13/Scripts/OneClickArchiver]]
importScript( 'User:DannyS712/Draft no cat.js' );// [[User:DannyS712/Draft no cat.js]]
importScript('User:Mr. Stradivarius/gadgets/Draftify.js'); // Linkback: [[User:Mr. Stradivarius/gadgets/Draftify.js]]
// Add [[WP:Reflinks]] launcher in the toolbox on left
$(function () {
mw.util.addPortletLink(
"p-tb", // toolbox portlet
"http://dispenser.homenet.org/~dispenser/cgi-bin/webreflinks.py/" + mw.config.get('wgPageName')
+ "?client=script&citeweb=on&overwrite=&limit=20&lang=" + mw.config.get('wgContentLanguage'),
"Reflinks" // link label
)});