User:Z.E.R.O./Steel359.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. |
Documentation for this user script can be added at User:Z.E.R.O./Steel359. |
// <pre><nowiki>
// [[User:Lupin/popups.js]]
importScript('User:Lupin/popups.js');
popupHideDelay=0.0;
popupAdminLinks=true;
popupOnEditSelection=false;
popupFixDabs=true;
popupRedlinkRemoval=true
// importScript('User:Steel359/helper.js'); // From User:GeorgeMoney/UserScripts/helpers/all
// importScript('User:Steel359/csd.js'); // From User:GeorgeMoney/csd.js
importScript('User:Steel359/morebits.js'); // From User:AzaToth/morebits.js
// importScript('User:Steel359/twinkleprotect.js'); // From User:AzaToth/twinkleprotect.js
importScript('User:Steel359/twinkle.js'); // From User:AzaToth/twinklespeedy.js
importScript('User:Steel359/salt.js'); // From User:AzaToth/salt.js
importScript('User:Voice_of_All/Addtabs/monobook.js');
importScript('User:Voice_of_All/replacetxt.js');
importScript('User:Steel359/VoA.js'); // From User:Voice_of_All/Specialadmin/monobook.js
importScript('User:Cryptic/toggleundelete.js');
importScript('User:Steel359/watchlist.js');
importScript('User:Steel359/tag.js');
disableRealTitle = 1;
// User creation log quickblock ------------------------------
function runOnloadHook(){
urlString = document.location.href;
if(urlString.search("newusers")>0){
bC = document.getElementById("bodyContent");
liArray = bC.getElementsByTagName("li");
for(i=0;i<liArray.length;i++){
liANode = liArray[i].childNodes[1];
liANodeNext = liArray[i].childNodes[8];
liA = liANode.innerHTML;
newAtext = "http://en.wikipedia.org/w/index.php?title=Special:Blockip&action=submit&wpBlockAddress=";
newAtext = newAtext + liA;
newAtext = newAtext + "&wpBlockExpiry=indefinite&wpBlockReason={{unb}}&wpEditToken=<token>";
var newdash = document.createTextNode(" | ");
xliA = liArray[i].childNodes[5].cloneNode(true);
liArray[i].insertBefore(xliA,liANodeNext);
xliA.innerHTML = "quickblock";
xliA.href = newAtext;
xliA.title = "Quick block this user";
xliA.className = "extiw";
liArray[i].insertBefore(newdash,xliA);
}
}
}
// AfD helper.js & easy voting ------------------------------------
document.write('<script type="text/javascript"' +
'src="http://en.wikipedia.org/w/index.php?title=User:Jnothman/afd_helper/' +
'script.js&action=raw&ctype=text/javascript&dontcountme=s"></script>');
function addLink(where, url, name, id, title, key, after) {
// addLink() accepts either an id or a DOM node, mw.util.addPortletLink() only takes a node
if (after && !after.cloneNode)
after = document.getElementById(after);
return mw.util.addPortletLink(where, url, name, id, title, key, after);
}
function autoafd_result()
{
var close = prompt("Result of debate?")
var f = document.editform, t = f.wpTextbox1;
t.value = t.value.split('{{REMOVE THIS TEMPLATE WHEN CLOSING THIS AfD').join('{{subst:User:Steel359/Empty');
t.value = "{{subst:" + "at" + "}} '''" + close + "'''. " + "~" + "~" + "~" + "~" + '\n' + '\n' + t.value;
if (t.value.length > 0)
t.value += '\n';
t.value += "{{subst:" + "ab" + "}}";
f.wpSummary.value = "AfD Closed, result was " + close;
}
function autoafd_add_afd_tabs()
{
// Only add for pages with the right string somewhere in the title
if (document.title.indexOf("Editing Wikipedia:Articles for deletion/") != -1)
{
mw.util.addPortletLink('p-cactions', 'javascript:autoafd_result()', "close");
}
}
$(autoafd_add_afd_tabs);
// Navigation -----------------------------------
$(function () {
// if this is a user, show the logs for the user rather than the page
if ( wgCanonicalNamespace == "User" || wgCanonicalNamespace == "User_talk" ) {
url = wgServer + "/w/index.php?title=Special:Log&user=" + wgTitle.split("/")[0];
} else if ( wgCanonicalNamespace == "Special" ) {
// don't display link for special pages
return;
} else {
url = wgServer + "/w/index.php?title=Special:Log&page=" + wgPageName;
}
mw.util.addPortletLink("p-navigation", url, "Logs", "pt-logs");
if ( wgCanonicalNamespace == "User" || wgCanonicalNamespace == "User_talk" ) {
url = wgServer + "/w/index.php?title=Special:Listusers&limit=1&username=" + wgTitle.split("/")[0];
} else {
return;
}
mw.util.addPortletLink("p-navigation", url, "User rights", "pt-rights");
if ( wgCanonicalNamespace == "User" || wgCanonicalNamespace == "User_talk" ) {
url = wgServer + "/w/index.php?title=Special:Prefixindex&namespace=2&from=" + wgTitle.split("/")[0] + '/';
} else {
return;
}
mw.util.addPortletLink("p-navigation", url, "Userspace", "pt-space");
});
// Vandalwarn -----------------------------------
function warnvandal()
{
var warn = prompt("Which warning?")
if( !warn ) {
return;
}
var f = document.editform, t = f.wpTextbox1;
if (t.value.length > 0)
t.value += '\n';
t.value += '\n' + "{{subst:" + warn + "}} ~~" + "~~";
f.wpSummary.value = warn;
}
function warnvandalb()
{
// Only add for pages with the right string somewhere in the title
if (document.title.indexOf("Editing User talk:") != -1)
{
mw.util.addPortletLink('p-cactions', 'javascript:warnvandal()', "warn" );
}
}
$(warnvandalb);