MediaWiki:CustomButton/code.js

// 22:29, July 7, 2015 (UTC) // created by Curiouscrab // use "link = URL;" to set destination of button // use "id = ID;" to set the id of the button // use "tooltip = HOVERTEXT;" to set the text that displays when hovered over // use "accesskey = ACCESSKEY;" to set the accesskey // use "wikitext = TEXT;" to set the text that displays on the button var link; var id; var tooltip; var accesskey; var wikitext; if(skin=='oasis') { $('.WikiaMenuElement').append('' + wikitext + ''); } else if(document.getElementById('ca-viewsource')!==undefined) { $('.pBody ul').append('' + wikitext + '') }