importScriptPage('ShowHide/code.js','dev');function rewriteTitle(){if(typeof(window.SKIP_TITLE_REWRITE)!='undefined'&&window.SKIP_TITLE_REWRITE)return;var titleDiv=document.getElementById('title-meta');if(titleDiv==null)return;var cloneNode=titleDiv.cloneNode(true);var firstHeading=getFirstHeading();var node=firstHeading.childNodes[0];firstHeading.replaceChild(cloneNode,node);cloneNode.style.display="inline";var titleAlign=document.getElementById('title-align');firstHeading.style.textAlign=titleAlign.childNodes[0].nodeValue;}function showEras(className){if(typeof(SKIP_ERAS)!='undefined'&&SKIP_ERAS)return;var titleDiv=document.getElementById(className);if(titleDiv==null||titleDiv==undefined)return;var cloneNode=titleDiv.cloneNode(true);var firstHeading=getFirstHeading();firstHeading.insertBefore(cloneNode,firstHeading.childNodes[0]);cloneNode.style.display="block";}function initVisibility(){var storage=globalStorage[window.location.hostname];var page=window.pageName.replace(/\W/g,'_');
var show=storage.getItem('infoboxshow-'+page);if(show=='false'){infoboxToggle();}var hidables=getElementsByClass('hidable');for(var i=0;i<hidables.length;i++){show=storage.getItem('hidableshow-'+i+'_'+page);if(show=='false'){var content=getElementsByClass('hidable-content',hidables[i]);var button=getElementsByClass('hidable-button',hidables[i]);if(content!=null&&content.length>0&&button!=null&&button.length>0&&content[0].style.display!='none'){button[0].onclick('bypass');}}else if(show=='true'){var content=getElementsByClass('hidable-content',hidables[i]);var button=getElementsByClass('hidable-button',hidables[i]);if(content!=null&&content.length>0&&button!=null&&button.length>0&&content[0].style.display=='none'){button[0].onclick('bypass');}}}}function onArticleNavClick(){var div=document.getElementById('mp3-nav');if(div.style.display=='block')div.style.display='none';else div.style.display='block';}function addAlternatingRowColors(){var infoboxes=getElementsByClass('infobox',document
.getElementById('content'));if(infoboxes.length==0)return;for(var k=0;k<infoboxes.length;k++){var infobox=infoboxes[k];var rows=infobox.getElementsByTagName('tr');var changeColor=false;for(var i=0;i<rows.length;i++){if(rows[i].className.indexOf('infoboxstopalt')!=-1)break;var ths=rows[i].getElementsByTagName('th');if(ths.length>0){continue;}if(changeColor)rows[i].style.backgroundColor='#f9f9f9';changeColor=!changeColor;}}}function addHideButtons(){var hidables=getElementsByClass('hidable');for(var i=0;i<hidables.length;i++){var box=hidables[i];var button=getElementsByClass('hidable-button',box,'span');if(button!=null&&button.length>0){button=button[0];button.onclick=toggleHidable;button.appendChild(document.createTextNode('[Hide]'));if(new ClassTester('start-hidden').isMatch(box))button.onclick('bypass');}}}function toggleHidable(bypassStorage){var parent=getParentByClass('hidable',this);var content=getElementsByClass('hidable-content',parent);var nowShown;if(content!=null&&content.
length>0){content=content[0];if(content.style.display=='none'){content.style.display=content.oldDisplayStyle;this.firstChild.nodeValue='[Hide]';nowShown=true;}else{content.oldDisplayStyle=content.style.display;content.style.display='none';this.firstChild.nodeValue='[Show]';nowShown=false;}if(window.storagePresent&&(typeof(bypassStorage)=='undefined'||bypassStorage!='bypass')){var page=window.pageName.replace(/\W/g,'_');var items=getElementsByClass('hidable');var item=-1;for(var i=0;i<items.length;i++){if(items[i]==parent){item=i;break;}}if(item==-1){return;}var storage=globalStorage[window.location.hostname];storage.setItem('hidableshow-'+item+'_'+page,nowShown);}}}function substUsernameTOC(){var toc=document.getElementById('toc');var userpage=document.getElementById('pt-userpage');if(!userpage||!toc)return;var username=userpage.firstChild.firstChild.nodeValue;var elements=getElementsByClass('toctext',toc,'span');for(var i=0;i<elements.length;i++)elements[i].firstChild.nodeValue=
elements[i].firstChild.nodeValue.replace('<insert name here>',username);}function replaceSearchIcon(){var searchbox=document.getElementById('searchBody');if(searchbox==null)return;var innerDiv=searchbox.getElementsByTagName('div')[0];if(innerDiv==null)return;var link=innerDiv.getElementsByTagName('a')[0];if(link)innerDiv.removeChild(link);var loader=new ContentLoader();loader.div=innerDiv;loader.callback=onSearchIconsArrival;loader.send('/index.php?title=Template:Searchicons&action=raw');}function rand(n){return Math.round(Math.random()*n);}function onSearchIconsArrival(){var lines=this.text.split('\n');var line=lines[rand(lines.length-1)];var pos=line.indexOf(' ');var link=document.createElement('div');link.id='search-icon-wrapper';var img=document.createElement('img');img.alt='Search';img.src=(pos==-1)?line:line.substring(0,pos);link.appendChild(img);this.div.insertBefore(link,this.div.firstChild);var div=document.createElement('div');div.id='search-popup';div.style.display='none';
var ul=document.createElement('ul');var li;var a;li=document.createElement('li');a=document.createElement('a');a.href='/index.php?title=Special:Search&adv=1';a.appendChild(document.createTextNode('Advanced search'));li.appendChild(a);ul.appendChild(li);li=document.createElement('li');a=document.createElement('a');a.href=(pos==-1)?'javascript:emptySearchDesc()':'/wiki/'+line.substring(pos+1);a.appendChild(document.createTextNode("What's this? ("+((pos==-1)?'NO DESCRIPTION':line.substring(pos+1))+')'));li.appendChild(a);ul.appendChild(li);li=document.createElement('li');a=document.createElement('a');a.href='javascript:closeSearchPopup()';a.appendChild(document.createTextNode("Close"));li.appendChild(a);ul.appendChild(li);div.appendChild(ul);document.getElementById('globalWrapper').appendChild(div);link.onclick=openSearchPopup;}function openSearchPopup(event){var div=document.getElementById('search-popup');var e=event||window.event;div.style.display=(div.style.display=='none')?'block':
'none';div.style.left=e.clientX+'px';div.style.top=(e.clientY+document.documentElement.scrollTop)+'px';}function closeSearchPopup(){document.getElementById('search-popup').style.display='none';}function emptySearchDesc(){alert('No description exists for this search icon. Please contact the administrators to resolve this problem.');}skinjs={"Logout":"Logout.js"}
var re=RegExp("(.*) - Darthipedia, the Star Wars Humor Wiki");var matches=re.exec(document.title);var skinNamejs;if(matches){if(skinjs[matches[1]]!=undefined){skinNamejs=(skinjs[matches[1]].length>0)?skinjs[matches[1]]:matches[1]+'.js';document.write('<script type="text/javascript" src="/index.php?title=MediaWiki:Skin/'+skinNamejs+'&action=raw&ctype=text/javascript"></script>');}}addOnloadHook(UserNameReplace);function UserNameReplace(){if(typeof(disableUsernameReplace)!='undefined'&&disableUsernameReplace)return;for(var i=0;UserName=document.getElementsByTagName("span")[i];i++){if((document.getElementById('pt-userpage'))&&(UserName.getAttribute('id')=="insertusername")){UserName.innerHTML=wgUserName;}}}var overrideNamespaces;var overrideGroups;function includeJS(page,onWikia,expand){document.write('<script type="text/javascript" src="'+(onWikia?'http://'+onWikia+'.wikia.com':'')+'/index.php?title='+page+'&action=raw&ctype=text/javascript&dontcountme=s'+(expand==false?'':
'&templates=expand')+'"></script>');}function includeJSCode(code){document.write('<script type="text/javascript">'+code+'</script>');}function includeCSS(page,onWikia,expand){document.write('<style type="text/css">/*<![CDATA[*/@import "'+(onWikia?'http://'+onWikia+'.wikia.com':'')+'/index.php?title='+page+'&action=raw&ctype=text/css'+(expand==false?'':'&templates=expand')+'";/*]]>*/</style>');}function includeCSSCode(code){document.write('<style type="text/css">/*<![CDATA[*/'+code+'";/*]]>*/</style>');}includeJS((overrideNamespaces?overrideNamespaces:'MediaWiki:Namespaces.js'));includeJS((overrideGroups?overrideGroups:'MediaWiki:Groups.js'));function updatetimer(i){var now=new Date();var then=timers[i].eventdate;var diff=count=Math.floor((then.getTime()-now.getTime())/1000);if(isNaN(diff)){timers[i].firstChild.nodeValue='** '+timers[i].eventdate+' **';return;}var left=(diff%60)+' seconds';diff=Math.floor(diff/60);if(diff>0)left=(diff%60)+' minutes '+left;diff=Math.floor(diff/60);if(
diff>0)left=(diff%24)+' hours '+left;diff=Math.floor(diff/24);if(diff>0)left=diff+' days '+left
timers[i].firstChild.nodeValue=left;timeouts[i]=setTimeout('updatetimer('+i+')',1000);}function checktimers(){var nocountdowns=getElementsByClassName(document,'span','nocountdown');for(var i=0;i<nocountdowns.length;i++)nocountdowns[i].style.display='none'
var countdowns=getElementsByClassName(document,'span','countdown');for(var i=0;i<countdowns.length;i++)countdowns[i].style.display='inline'
timers=getElementsByClassName(document,'span','countdowndate');timeouts=new Array();if(timers.length==0)return;for(var i=0;i<timers.length;i++){timers[i].eventdate=new Date(timers[i].firstChild.nodeValue);updatetimer(i);}}addOnloadHook(checktimers);var ajaxIndicator='http://images2.wikia.nocookie.net/dev/images/8/82/Facebook_throbber.gif',ajaxTimer,ajaxRefresh=60000,refreshText='Auto-Refresh',refreshHover='Enable auto-refreshing of this page',doRefresh=true;if(!window.ajaxPages){var ajaxPages=new Array('Special:RecentChanges','Special:WikiActivity');}if(!window.ajaxCallAgain){ajaxCallAgain=[];}if(typeof AjaxRCRefreshText=="string"){refreshText=AjaxRCRefreshText;}if(typeof AjaxRCRefreshHoverText=="string"){refreshHover=AjaxRCRefreshHoverText;}function setCookie(c_name,value,expiredays){var exdate=new Date();exdate.setDate(exdate.getDate()+expiredays);document.cookie=c_name+"="+escape(value)+((expiredays===null)?"":";expires="+exdate.toGMTString());}function getCookie(c_name){if(document
.cookie.length>0){var c_start=document.cookie.indexOf(c_name+"=")
if(c_start!==-1){c_start=c_start+c_name.length+1;var c_end=document.cookie.indexOf(";",c_start);if(c_end===-1){c_end=document.cookie.length;}return unescape(document.cookie.substring(c_start,c_end));}}return"";}function preloadAJAXRL(){var ajaxRLCookie=(getCookie("ajaxload-"+wgPageName)=="on")?true:false,appTo=($('#WikiaPageHeader').length)?$('#WikiaPageHeader'):($('#AdminDashboardHeader').length?$('#AdminDashboardHeader > h1'):$('.firstHeading'));appTo.append('&nbsp;<span style="font-size: xx-small; line-height: 100%;" id="ajaxRefresh"><span style="border-bottom: 1px dotted; cursor: help;" id="ajaxToggleText" title="'+refreshHover+'">'+refreshText+':</span><input type="checkbox" style="margin-bottom: 0;" id="ajaxToggle"><span style="display: none;" id="ajaxLoadProgress"><img src="'+ajaxIndicator+'" style="vertical-align: baseline; float: none;" border="0" alt="Refreshing page" /></span></span>');$('#ajaxLoadProgress').ajaxSend(function(event,xhr,settings){if(location.href==settings.
url){$(this).show();}}).ajaxComplete(function(event,xhr,settings){if(location.href==settings.url){$(this).hide();for(i in ajaxCallAgain){ajaxCallAgain[i]();}}});$('#ajaxToggle').click(toggleAjaxReload);$('#ajaxToggle').attr('checked',ajaxRLCookie);if(getCookie("ajaxload-"+wgPageName)=="on"){loadPageData();}}function toggleAjaxReload(){if($('#ajaxToggle').prop('checked')==true){setCookie("ajaxload-"+wgPageName,"on",30);doRefresh=true;loadPageData();}else{setCookie("ajaxload-"+wgPageName,"off",30);doRefresh=false;clearTimeout(ajaxTimer);}}function loadPageData(){var cC=($('#WikiaArticle').length)?'#WikiaArticle':'#bodyContent';$(cC).load(location.href+" "+cC+" > *",function(data){if(doRefresh){ajaxTimer=setTimeout("loadPageData();",ajaxRefresh);}});}$(function(){for(x in ajaxPages){if(wgPageName==ajaxPages[x]&&$('#ajaxToggle').length===0){preloadAJAXRL();}}});var refreshDate;function addDate(){var UTCDate=((new Date()).toUTCString()).replace("GMT","(UTC)");$('#showdate').empty().append(
'<span class="barDate" style="font-weight: bold; text-transform: none;"><a style="color:white;" title="Purge the server cache and update the contents of this page." href="'+wgArticlePath.replace('$1',wgPageName.replace(/ /g,'_'))+'?action=purge">'+UTCDate.substring(5)+'</a></span>');window.clearTimeout(refreshDate);refreshDate=window.setTimeout(addDate,1000);}$(document).ready(function(){if(skin=='oasis')$('<li id="displayTimer"><span id="showdate"></span></li>').appendTo('#GlobalNavigation');else $('#p-personal ul').prepend('<li><span id="showdate"></span></li>');addDate();refreshDate=window.setTimeout(addDate,1000);$('#displayTimer').css({'font-size':"12px"});});;var SocialMediaButtonsNamespaces=[0,6,14,500];var SocialMediaButtons={position:"top",colorScheme:"color",buttonSize:"35px",wikiTwitterAccount:"default"};importScriptPage('SocialIcons/code.js','dev');var refreshDate;function addDate(){var UTCDate=((new Date()).toUTCString()).replace("GMT","(UTC)");$('#showdate').empty().
append('<span class="barDate" style="font-weight: bold; text-transform: none;"><a style="color:white;" title="Purge the server cache and update the contents of this page." href="'+wgArticlePath.replace('$1',wgPageName.replace(/ /g,'_'))+'?action=purge">'+UTCDate.substring(5)+'</a></span>');window.clearTimeout(refreshDate);refreshDate=window.setTimeout(addDate,1000);}$(document).ready(function(){if(skin=='oasis')$('<li id="displayTimer"><span id="showdate"></span></li>').appendTo('#GlobalNavigation');else $('#p-personal ul').prepend('<li><span id="showdate"></span></li>');addDate();refreshDate=window.setTimeout(addDate,1000);$('#displayTimer').css({'font-size':"12px"});});;;mw.loader.state({"site":"ready"});

/* cache key: futurama:resourceloader:filter:minify-js:7:47400dbe3d9933d443e6764bc727e6ba */