Benutzer:Porthos (MA)/monobook.js: Unterschied zwischen den Versionen
imported>Porthos |
K (Phoenixclaw verschob die Seite Benutzer:Porthos/monobook.js nach Benutzer:Porthos (MA)/monobook.js, ohne dabei eine Weiterleitung anzulegen) |
(kein Unterschied)
|
Aktuelle Version vom 18. April 2021, 20:49 Uhr
function newTool(text,desc) {
var tool = document.createElement("a");
tool.href = "javascript:inserts('"+text+" ','')";
var toolTxt = document.createTextNode(desc);
tool.appendChild(toolTxt);
return tool;
}
function moreTools() {
var tools = document.getElementById('moretools');
tools.appendChild(newTool('+','Added'));
tools.appendChild(document.createTextNode(" | "));
tools.appendChild(newTool('fix','Fixed'));
tools.appendChild(document.createTextNode(" | "));
tools.appendChild(newTool('rev','Reverted'));
tools.appendChild(document.createTextNode(" | "));
tools.appendChild(newTool('Vandalismus','Vandalismus'));
tools.appendChild(document.createTextNode(" | "));
tools.appendChild(newTool('erg','ergänzt'));
tools.appendChild(document.createTextNode(" | "));
tools.appendChild(newTool('wiki','wikifiziert'));
tools.appendChild(document.createTextNode(" | "));
tools.appendChild(newTool('typo','Typo'));
tools.appendChild(document.createTextNode(" | "));
tools.appendChild(newTool('links','Links'));
tools.appendChild(document.createTextNode(" | "));
tools.appendChild(newTool('kat','Kategorie'));
tools.appendChild(document.createTextNode(" | "));
tools.appendChild(newTool('en','Interwiki en'));
tools.appendChild(document.createTextNode(" | "));
tools.appendChild(newTool('format','Formatierung'));
tools.appendChild(document.createTextNode(" | "));
tools.appendChild(newTool('Bild','Bild'));
tools.appendChild(document.createTextNode(" | "));
tools.appendChild(newTool('Darsteller','Darsteller'));
tools.appendChild(document.createTextNode(" | "));
tools.appendChild(newTool('Referenz','Referenz'));
tools.appendChild(document.createElement("BR"));
}
if (window.addEventListener) window.addEventListener("load",moreTools,false);
else if (window.attachEvent) window.attachEvent("onload",moreTools);
function inserts(tag, sampleText) {
var txtarea = document.editform.wpSummary;
txtarea.value = txtarea.value + tag;
}