User:Jens Ingels/common.js

$('div.eggs-filter').prepend($('div.bm_dragon_name')); //eggs-terra (function {  var countg = 0;  $("div#but-terra").click(function  { countg += 1; if (countg == 1) { $( "div.bt-terra" ).css( "background-position", "top" ); $( "div.e1_terra" ).toggleClass( "eggs-hide" ); $( "div.e2_terra" ).toggleClass( "eggs-hide2" ); $( "div.e3_terra" ).toggleClass( "eggs-hide3" ); }   if (countg == 2) { $( "div.bt-terra" ).css( "background-position", "bottom" ); $( "div.e1_terra" ).toggleClass( "eggs-hide" ); $( "div.e2_terra" ).toggleClass( "eggs-hide2" ); $( "div.e3_terra" ).toggleClass( "eggs-hide3" ); countg = 0 } }); });

//eggs-flame (function {  var countg = 0;  $("div#but-flame").click(function  { countg += 1; if (countg == 1) { $( "div.e1_flame" ).toggleClass( "eggs-hide" ); $( "div.e2_flame" ).toggleClass( "eggs-hide2" ); $( "div.e3_flame" ).toggleClass( "eggs-hide3" ); }   if (countg == 2) { $( "div.e1_flame" ).toggleClass( "eggs-hide" ); $( "div.e2_flame" ).toggleClass( "eggs-hide2" ); $( "div.e3_flame" ).toggleClass( "eggs-hide3" ); countg = 0 } }); });

//eggs-sea (function {  var countg = 0;  $("div#but-sea").click(function  { countg += 1; if (countg == 1) { $( "div.e1_sea" ).toggleClass( "eggs-hide" ); $( "div.e2_sea" ).toggleClass( "eggs-hide2" ); $( "div.e3_sea" ).toggleClass( "eggs-hide3" ); }   if (countg == 2) { $( "div.e1_sea" ).toggleClass( "eggs-hide" ); $( "div.e2_sea" ).toggleClass( "eggs-hide2" ); $( "div.e3_sea" ).toggleClass( "eggs-hide3" ); countg = 0 } }); });

/* testing */

$( "div#but-id" ).click(function { function sortAlpha(a,b){     return a.innerHTML.toLowerCase > b.innerHTML.toLowerCase ? 1 : -1;  };  $('div#id div').sort(sortAlpha).appendTo('div#id'); });

/* other */

$(document).ready(function {   var pageName = $('div#tooltip-link').text;

$('div#tooltip-link').load('http://dragoncity.wikia.com/wiki/' + pageName + '' + '#tooltip-content'); });

/* Test */ $("value","140881").prepend(' ');

$('ul.WikiaMenuElement').append( $(' ').attr({'name':'notify-admin', 'id':'notify-admin','type':'checkbox'}) ) .append( $(' ').text( $.msg('wall-action-all-confirm-notify') ) );

importArticles({   type: "script",    articles: [        "User:Jens_Ingels/common.js/test.js",        "external:dev:HideRail/code.js",        "external:dev:MessageBlocker/code.js"    ] });

/* Add JS buttom to Account Navigation in the Wikia skin */ $('[name="destinationBoardId"]').children('option[value="130215"]').css('display','none');

$(document).ready(function {   if ( skin == 'oasis' )        $( 'UL#AccountNavigation' ).prepend( 'JS  PersonalWiki-wide</li>' ); });

/* Add CSS buttom to Account Navigation in the Wikia skin */ $(document).ready(function {   if ( skin == 'oasis' )        $( 'UL#AccountNavigation' ).prepend( '<li id="CSS-USER">CSS<img class="chevron" src="data:image/gif;base64,R0lGODlhAQABAIABAAAAAP///yH5BAEAAAEALAAAAAABAAEAQAICTAEAOw%3D%3D"> </a> <li id="CSS">Personal</a></li><li id="WIKI-CSS">Wiki-wide</a></li></ul></li>' ); });

/* Add SANDBOX buttom to Account Navigation in the Wikia skin */ $(document).ready(function {   if ( skin == 'oasis' )        $( 'UL#AccountNavigation' ).prepend( '<li id="SANDBOX-USER"">SANDBOX<img class="chevron" src="data:image/gif;base64,R0lGODlhAQABAIABAAAAAP///yH5BAEAAAEALAAAAAABAAEAQAICTAEAOw%3D%3D"> </a> <li id="SANDBOX">10</a></li><li id="SANDBOX11">11</a></li><li id="SANDBOX12">12</a></li><li id="SANDBOX13">13</a></li><li id="SANDBOX14">14</a></li><li id="SANDBOX15">15</a></li><li id="SANDBOX16">16</a></li><li id="SANDBOX17">17</a></li></ul></li>' ); });

/* Add Infobox project buttom to Account Navigation in the Wikia skin */ $(document).ready(function {   if ( skin == 'oasis' )        $( 'UL#AccountNavigation' ).prepend( '<li id="PROJECT">PROJECT</a></li>' ); });

/* Add test js to Account Navigation in the Wikia skin */ $(document).ready(function {   if ( skin == 'oasis' )        $( 'UL#AccountNavigation' ).prepend( '<li id="TEST JS"">TEST JS</a></li>' ); });

// Adding links to On the Wiki tab // Modified to add links to the end of the tab instead of the beginning by Sactage // Please note that he in no way endorses this code and is not liable for any issues which may arise from its use, legal or otherwise // Per http://runescape.wikia.com/wiki/User_talk:Ryan_PM?diff=prev&oldid=4890582 $(function {   if ( skin == 'oasis' ) {        $('.WikiHeaderRestyle nav ul li.marked ul').append('About</a></li>');    } });

/* Add SANDBOX3 buttom to Account Navigation in the Wikia skin */ $(document).ready(function {   if ( skin == 'oasis' )        $( 'UL#AccountNavigation' ).prepend( '<li id="SANDBOX9"><a href="/wiki/Special:Mypage/Sandbox/9" style="font-size:12px">SANDBOX9</a></li>' ); });