User:Daniel Letalis/global.js

/* if (skin == 'oasis') { wr_read_cookie = function(name) { var i, c, cl = document.cookie.split(';'); for(i=0;i<cl.length;i++) { c = $.trim(cl[i]); if (c.indexOf(name+'=') === 0) { return c.substring(name.length+1); } } return null; };

wr_write_cookie = function(name, val) { var date = new Date; date.setTime(date.getTime+(30*24*60*60*1000)); date = date.toGMTString; document.cookie = name+'='+val+'; expires='+date+'; path=/'; }; WikiaRailCToggler = function(page_loaded) { if (typeof $ !== 'undefined' && $('#WikiaRail').size) { $('#WikiaRail').after($('    ')); $('#WikiaRailToggler div').attr('style', 'border-style:solid;border-bottom-color:transparent;border-bottom-width:6px;border-left-color:#006cb0;border-left-width:0px;border-right-color:#006cb0;border-right-width:6px;border-top-color:transparent;border-top-width:6px;'); $('#WikiaRailToggler').toggle(function {     WikiaRailCTogglerOW = parseInt($('#WikiaMainContent').css('width'));      $('#WikiaMainContent').width(WikiaRailCTogglerOW + 320);      $('#WikiaRail').css('display', 'none');      $('#WikiaRailToggler div').css({'border-left-width':'6px', 'border-right-width':'0px'});      wr_write_cookie('WikiaRail_CHide', '1');    }, function {      $('#WikiaMainContent').width(WikiaRailCTogglerOW);      $('#WikiaRail').css('display', '');      $('#WikiaRailToggler div').css({'border-left-width':'0px', 'border-right-width':'6px'});      wr_write_cookie('WikiaRail_CHide', '0');    }); if (wr_read_cookie('WikiaRail_CHide') == '1') { $('#WikiaRailToggler').click; } } else if (!page_loaded) { WikiaRailCTogglerT = setTimeout(function { WikiaRailCToggler; }, 100); } }; WikiaRailCTogglerT = 0; WikiaRailCToggler; WikiaRailCTogglerOW = '';

addOnloadHook(function { clearTimeout(WikiaRailCTogglerT); }); }