User:Seeaver/monobook.js

if (   document.getElementsByTagName("body")[0].classList.contains("page-Main_Page")		&&  	document.getElementsByTagName("body")[0].classList.contains("action-view") )  ( 	document.getElementById("content").innerHTML=	" "  // Intro music );

//

// Idea for next April Fools function fakeRename { fakeUsername = prompt("Choose your preferred new user name",                document.getElementById("pt-userpage").getElementsByTagName("a")[0].innerHTML                 // puts current name into dialogue box        ); if (fakeUsername === null) return; // "Cancel" button handler fakeUsername = capitalizeFirstLetter(fakeUsername); document.getElementById("pt-userpage").getElementsByTagName("a")[0].innerHTML = fakeUsername; location.hash="#pt-userpage"; alert("Your user name has been successfully changed!"); }

// Source: https://stackoverflow.com/a/1026087 function capitalizeFirstLetter(string) { return string.charAt(0).toUpperCase + string.slice(1); }

// Insert fake "Change my user name" link at page bottom if ( document.getElementById("footer") ) /* check if element exists, to prevent errors */ { document.getElementById("footer").getElementsByTagName("ul")[0].innerHTML = (    document.getElementById("footer").getElementsByTagName("ul")[0].innerHTML+'Change my user name' // add link as last point ); }