User:Heuler06/monobook.js

// function logs { var list=document.getElementById("n-mainpage").parentNode; list.innerHTML+='Logs'; } function SpecialChar { function $(id) { return document.getElementById(id); } var search = $("editpage-specialchars"); var search1 = $("editpage-copywarn"); if(search!=null && search1!=null) {  $("editform").insertBefore(search, search1); }; }

var mark=false, change=false; function markIPs(change) { var searchExp=/Recent changes/i; var heading=document.getElementsByTagName("title")[0].text; if (mark && change) {  mark=false; } else {  mark=true; }; if (searchExp.test(heading)) {        // Falls die Seite im Titel "Letzte Änderungen" zu stehen hat, mache folgendes. var i=0; var el=document.getElementsByTagName("li"); // In den Listenelementen searchExp=/Special:Contributions\/\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}/; // IPs (hier als Struktur von 4 Ziffernblöcken mit je           // mindestens einer Zahl getrennt durch einen Punkt) searchMe=/User:Heuler06/; while (i<el.length) {   var marker=document.createAttribute("style"); var ip=searchExp.test(el[i].innerHTML); // heraussuchen var me=searchMe.test(el[i].innerHTML); if (mark) {    if (ip) {marker.nodeValue="background:#ffffbb;";} else {if (me) {marker.nodeValue="background:#ffdddd;";};}; }   else {    marker.nodeValue="background:#F8FCFF;"; };   if (ip || me) {    el[i].setAttributeNode(marker); // und gelb markieren. };   i++; }; }; }

function sla { var str="\n\n";

if (reason!="" && !reason.null) {  document.editform.wpSummary.value="speedy deletion"; document.editform.wpTextbox1.value=str; document.editform.wpTextbox1.value+=text; }; }

function addLinksToMenu { var sExpReCh=/Recent Changes/i; var sExpEdit=/Editing/i; var heading=document.getElementsByTagName("title")[0].text; var toolsNode=document.getElementById("t-specialpages").parentNode; innerHTML='Own: \n'; if (sExpReCh.test(heading) || sExpEdit.test(heading)) {  if (sExpReCh.test(heading)) {   innerHTML+='Marker on/off'; }  else {   innerHTML+='SLA'; }; };  toolsNode.innerHTML+=innerHTML; }; addOnloadHook(logs); addOnloadHook(SpecialChar); addOnloadHook(markIPs); addOnloadHook(addLinksToMenu); //