367
edits
Changes
Jump to navigation
Jump to search
/**************************************************************************************//*******************Darth Stabro Scripts***********************************************//**************************************************************************************/ /** Username replace function for([[template:USERNAME]]) ******************************* * Inserts user name into <span class="insertusername"></span> / */ function UserNameReplace() { var disableUsernameReplace i = 0; if(typeof(disableUsernameReplace) != 'undefined' && disableUsernameReplace || wgUserName == null) returni < spans.length; var n = YAHOO.util.Dom.getElementsByClassName('insertusername', 'span', document.getElementById('bodyContent')i++); for ( var x in n ) { n spans[xi].innerHTML = wgUserName;
} addOnloadHook(UserNameReplace); /****************************************/
no edit summary
/*
Replaces {{USERNAME}} with the name of the user browsing the page.
Requires copying Template:USERNAME.
*/
function substUsername()
{
var spans = getElementsByClass('insertusername', null, 'span');
}