User:Iamthejabberwock/monobook.js

// //***Loader***// window.onload = Main; function Main { addlinks; }

//***Add User Talk Links***// function addlilink(tabs, url, name, id) { var na = document.crenateElement('a'); na.href = url; na.id = id; na.appendChild(document.createTextNode(name)); var li = document.createElement('li'); li.appendChild(na); tabs.appendChild(li); return li; }

function addlinks { var tabs = document.getElementById('p-cactions').getElementsByTagName('ul')[0]; if (document.title.indexOf("Editing User talk:") == 0) { addlilink(tabs, 'javascript:welcome', 'w', ''); addlilink(tabs, 'javascript:vandal("welcomenpov")', 'wnpov', ''); addlilink(tabs, 'javascript:editsummary', 'es', ''); addlilink(tabs, 'javascript:vandalask("test0-n")', 'tgf', ''); addlilink(tabs, 'javascript:vandalask("test-self-n")', 'ts', ''); addlilink(tabs, 'javascript:vandalask("test-n")', 't1', ''); addlilink(tabs, 'javascript:vandalask("spam-n")', 'spam', ''); addlilink(tabs, 'javascript:vandalask("vw")', 'bv1', ''); addlilink(tabs, 'javascript:vandalask("test2-n")', 't2', ''); addlilink(tabs, 'javascript:vandalask("spam-n")', 's2', '') addlilink(tabs, 'javascript:vandalask("test3-n")', 't3', ''); addlilink(tabs, 'javascript:vandalask("anon vandal-n")', 'ta3', ''); addlilink(tabs, 'javascript:vandalask("blatantvandal")', 'bv4', ''); } if (document.title.indexOf("Editing") == 0 && document.title.indexOf("Editing User") != 0) { addlilink(tabs, 'javascript:inuse', 'inuse', ''); } }

function welcome { var txt = document.editform.wpTextbox1; if (txt.value.length > 0) txt.value += '\n'; var type = prompt("user or anon?"); var article = prompt("article?"); var topic = prompt("topic?"); var portal = prompt("portal?"); var project = prompt("project?"); txt.value +=  + ; document.editform.wpSummary.value = 'welcome'; document.editform.wpWatchthis.checked = true; }

function vandal(tmplt) { var txt = document.editform.wpTextbox1; if (txt.value.length > 0) txt.value += '\n'; txt.value +=  + ; document.editform.wpSummary.value = '+'; document.editform.wpWatchthis.checked = true; }

function vandalask(tmplt) { var txt = document.editform.wpTextbox1; if (txt.value.length > 0) txt.value += '\n'; var article = prompt("article?"); txt.value +=  + article +  + ''; document.editform.wpSummary.value = '+'; document.editform.wpWatchthis.checked = true; }

function inuse { var txt = document.editform.wpTextbox1; if (txt.value.length > 0) txt.value += '\n'; var time = prompt("until?"); txt.value += '' document.editform.wpSummary.value = 'in use until' + time; document.editform.wpWatchthis.checked = true; }

function editsummary { var txt = document.editform.wpTextbox1; if (txt.value.length > 0) txt.value += '\n'; txt.value += '== Edit summaries == \n\n' + ''; document.editform.wpSummary.value = 'edit summaries'; document.editform.wpWatchthis.checked = true; }

//**Hide Own Edits In Watchlist**// addOnloadHook(function {  for (var i=0; i0) {    document.links[i].href+='?hideOwn=1';     break;   }  } });

//**Popups: User:Lupin/popups.js**

mw.loader.load(            'https://en.wikipedia.org/w/index.php?title=User:Lupin/popups.js'             + '&action=raw&ctype=text/javascript&dontcountme=s'); popupRevertSummary="rvv to version %s using popups" popupRevertSummaryPrompt=true popupDelay=1.5 popupImages=false simplePopups=false popupOnEditSelection=false

//**Install User:Cacycle/diff Text Diff Tool** document.write(' ');

//**Install User:Cacycle/editor Edit Tool**// document.write(' ');

//**Add [edit top] Link** (by User:Pile0nades)**//

//add link addOnloadHook(function {  //if this is preview page or generated page, stop  if (document.getElementById("wikiPreview") || window.location.href.indexOf("/wiki/Special:") != -1) return; // get page title  var pageTitle = document.title.split(" - ")[0].replace(" ", "_");  // create div and set innerHTML to link  var divContainer = document.createElement("div");  divContainer.innerHTML = ' [edit top] ';

// insert divContainer into the DOM before the h1 if (window.location.href.indexOf("&action=edit") == -1) document.getElementById("content").insertBefore(divContainer, document.getElementsByTagName("h1")[0]);

if(window.location.href.indexOf("&action=edit&section=0") != -1) document.getElementById("wpSummary").value = "/* Intro */ "; }); //