User:MER-C/monobook.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:MER-C/monobook.css. |
// <pre><nowiki>
function inc (file) {
var lt = String.fromCharCode(60);
var gt = String.fromCharCode(62);
document.writeln(lt+'script type="text/javascript" src="/w/index.php?title='+file+'&action=raw&ctype=text/javascript&dontcountme=s"'+gt+lt+'/script'+gt);
}
inc("User:VoA/monobook.js");
// speedy deletion warning
function dbwarn()
{
var title = document.title.substr(0, document.title.lastIndexOf(' - Wikipedia, the free'));
if (title.indexOf("Editing User talk") != -1)
{
var type = prompt("Enter page up for speedy deletion");
var f = document.editform, t = f.wpTextbox1;
t.value = t.value + "\n ==Speedy deletion warning== \n" + {{subst:nn-warn|" + type + "}} ~~~~ \n" ;
f.wpSummary.value = "User notice: nn-warn";
f.wpSave.click();
return;
}
}
addOnloadHook(function()
{
if (document.title.indexOf("Editing User talk:") != -1)
{
var c1 = document.getElementById('column-one');
var tabs = c1.getElementsByTagName('div')[0].getElementsByTagName('ul')[0];
tabs.appendChild(tnaddlilink('javascript:dbwarn()',"csd warn"));
}
});
//</nowiki></pre>
// [[Category:RC scripted users]]