User:Surriela/global.js

$(function {   $('#WikiaBarWrapper .toolbar .tools').css('float','right');    $('.menu.overflow-menu li').each(function { $(this).insertBefore('.mytools.menu'); });   $('.menu.overflow-menu').remove;

$('.WikiaHeader nav > ul > li + li').remove; $('.WikiaHeader nav > ul').append($(' ').hide); $('#WikiaSearch input:first').addClass('mysearch'); $('#WikiaSearch button').addClass('mysearchbutton'); if ($('form#WikiaSearch').length) { $('form#WikiaSearch').appendTo('#mysearch').attr('style','padding-left:15px; margin-top:-3px'); $('#mysearch').show; }   $('a[data-id="wikiactivity"]').attr({title:'Recent Changes',href:'/wiki/Special:RecentChanges'}).html('Recent Changes').clone.appendTo('ul.tools').wrap('').removeClass('wikia-button secondary'); if ($('.newarticletextbox').length) { $('.editpage-intro-wrapper .mw-newarticletext > p, #EditPageIntro .expand').remove; $('.editpage-intro > .editpage-intro-wrapper').css({padding: '0 5px 5px',background: '#F2F2F2'}); $('#EditPageIntro').css('border','1px solid #CCCCCC'); $('.newarticletextbox.quest a').attr('href',wgPageName + '?action=edit&preload=User:Surriela/Quest'); $('.newarticletextbox.npc a').attr('href',wgPageName + '?action=edit&preload=User:Surriela/NPC'); $('.newarticletextbox.item a').attr('href',wgPageName + '?action=edit&preload=User:Surriela/Item'); $('.newarticletextbox.weapon a').attr('href',wgPageName + '?action=edit&preload=User:Surriela/Weapon'); $('.newarticletextbox.armor a').attr('href',wgPageName + '?action=edit&preload=User:Surriela/Armor'); $('.newarticletextbox.skill a').attr('href',wgPageName + '?action=edit&preload=User:Surriela/Skill'); $('.newarticletextbox.object a').attr('href',wgPageName + '?action=edit&preload=User:Surriela/Object'); $('.newarticletextbox').parent.append(' Gatherable '); }   $('a[data-id="editprofile"]').html('Edit'); $('#wpSave').attr('value','Save'); $('.overflow a[data-name="prefixindex"]').html('My pages').attr('href','/wiki/Special:PrefixIndex?prefix=Surriela&namespace=2'); $('#my-tools-menu').css({left: 'auto', right: '108px'}); $('.tools-menu').css({left: 'auto', right: '188px'}); $('.AccountNavigation .subnav li:first').append('Wikia.cssWikia.js'); $('#WikiaArticle').unbind('click.lightbox');

var a = document.getElementsByTagName("a"); for ( var t = 0; t < a.length; ++t ) { var a2 = a[t]; var img = a2.getElementsByTagName("img"); if ( img[0] != null ) { if ( a2.href.indexOf("wikia.nocookie.net") != -1 ) { var link = wgServer + '/wiki/File:' + a2.getAttribute('data-image-name'); a2.setAttribute('href',link); }       }    }  // Detects non-existent file links and adds a button to change // links to edit the page rather than an upload page if ($('a.new[title*="File"]').length) { $('#WikiaPageHeader').append('Change Links').click(function {      $('a.new[title*="File"]').each(function  { $(this).attr('href', '/wiki/' + $(this).attr("title") + '?action=edit'); });   });  } });

PurgeButtonText = 'Purge'; importScriptPage('PurgeButton/code.js', 'dev');

if (mwCustomEditButtons) { mwCustomEditButtons[mwCustomEditButtons.length] = { "imageFile": "http://images4.wikia.nocookie.net/aion/images/4/4a/Button_welcome.png", "speedTip": "Welcome", "tagOpen": "{", "tagClose": "}}", "sampleText": "{subst:welcome|Surriela|" }; mwCustomEditButtons[mwCustomEditButtons.length] = { "imageFile": "http://images3.wikia.nocookie.net/aion/images/c/c8/Button_redirect.png", "speedTip": "Redirect file", "tagOpen": "#redirect [[File:",   "tagClose": "",     "sampleText": ""  }; }