User:BlueDevil/global.js

// var console;

// ***************************************************************** // Load various external scripts // ***************************************************************** function appendScript(url) { if(wgServer.indexOf('requests.wikia')!=-1) return; var scriptElem = document.createElement('script'); scriptElem.setAttribute('src',url); scriptElem.setAttribute('type','text/javascript'); document.getElementsByTagName('head')[0].appendChild(scriptElem); } appendScript('http://www.wikia.com/index.php?title=User:Splarka/contribtools.js&action=raw&ctype=text/javascript&dontcountme=s') appendScript('http://www.wikia.com/index.php?title=User:Splarka/stripsource.js&action=raw&ctype=text/javascript&dontcountme=s') appendScript('http://www.wikia.com/index.php?title=User:Splarka/fastdelete.js&action=raw&ctype=text/javascript&dontcountme=s') appendScript('http://www.wikia.com/index.php?title=User:Splarka/interwikitools.js&action=raw&ctype=text/javascript&dontcountme=s') appendScript('http://en.wikipedia.org/w/index.php?title=User:Zocky/SearchBox.js&action=raw&ctype=text/javascript&dontcountme=s')

if(skin=='monobook'){ appendScript('http://www.wikia.com/index.php?title=User:Sannse/Imagelisttools.js&action=raw&ctype=text/javascript&dontcountme=s') } // ***************************************************************** // Custom automatic delete buttons // ***************************************************************** // Adds customizable one-click deletion buttons to any deletable page. // Requires w:User:Splarka/fastdelete.js in appendScript; var fdButtons = []; fdButtons[fdButtons.length] = { 'summary': 'اسپم', 'hotkey': '8', 'label': 'اسپم'}; fdButtons[fdButtons.length] = { 'summary': 'خرابکاری', 'label': 'خرابکاری'};

// ***************************************************************** // &bot=1 on contribs pages. // ***************************************************************** function hiderollback { var botlink = document.location.href; if(botlink.indexOf('?')==-1) { botlink += '?bot=1'; } else { botlink += '&bot=1'; } addPortletLink('p-cactions', botlink, '&bot=1', 'ca-bot'); } if((skin == "monobook")&&(wgCanonicalSpecialPageName == 'Contributions')) addOnloadHook(hiderollback)

// ***************************************************************** // Custom edit buttons // ***************************************************************** if (mwCustomEditButtons) { mwCustomEditButtons[mwCustomEditButtons.length] = { "imageFile": "http://images.wikia.com/central/images/3/3c/Button_pre.png", "speedTip": " tag", "tagOpen": "\n", "tagClose": "\n", "sampleText": ""}; mwCustomEditButtons[mwCustomEditButtons.length] = { "imageFile": "http://images.wikia.com/central/images/2/23/Button_code.png", "speedTip": " ", "sampleText": ""}; mwCustomEditButtons[mwCustomEditButtons.length] = { "imageFile": "http://images.wikia.com/central/images/7/7b/Button_pre_nowiki.png", "speedTip": " tags", "tagOpen": "\n", "tagClose": "\n", "sampleText": ""}; mwCustomEditButtons[mwCustomEditButtons.length] = { "imageFile": "http://images.wikia.com/central/images/7/73/Button_code_nowiki.png", "speedTip": " ", "sampleText": ""}; mwCustomEditButtons[mwCustomEditButtons.length] = { "imageFile": "http://images.wikia.com/central/images/c/ce/Button_ampersand_lt-gt_semicolon.png", "speedTip": "&lt;tag here&gt;", "tagOpen": "&lt;", "tagClose": "&gt;", "sampleText": ""}; } // "Whine" button - initial idea by Jack, lots of helpful tweaks // by Splarka (http://www.wikia.com/wiki/User:Splarka) if (mwCustomEditButtons) { mwCustomEditButtons[mwCustomEditButtons.length] = { "imageFile": "http://images.wikia.com/central/images/3/3b/Button_template_alt.png", "speedTip": "", "tagOpen": "", "sampleText": "wikia:User:BlueDevil"}; mwCustomEditButtons[mwCustomEditButtons.length] = { "imageFile": "http://images.wikia.com/central/images/c/c8/Button_redirect.png", "speedTip": "Redirect", "tagOpen": "#REDIRECT ",    "tagClose": "", "sampleText": "w:User talk:BlueDevil"}; } //