MediaWiki:LogoChanger.js

/* */ var miniwikis = new Array( '^Sengoku Rance', '^Tsumashibori', '^Double Teacher Life', '^Beat Angel Escalayer' );

var monologos = new Array( 'http://images.wikia.com/alicesoft/images/thumb/d/da/Sengoku_Rance_-_logo.gif/150px-Sengoku_Rance_-_logo.gif', 'http://images.wikia.com/alicesoft/images/thumb/c/cd/Tsumashibori_-_logo.gif/150px-Tsumashibori_-_logo.gif', 'http://images.wikia.com/alicesoft/images/thumb/c/cc/Double_Teacher_Life_-_logo.gif/150px-Double_Teacher_Life_-_logo.gif', 'http://images.wikia.com/alicesoft/images/thumb/f/fb/Beat_Angel_Escalayer_-_logo.gif/150px-Beat_Angel_Escalayer_-_logo.gif' );

var quartzlogos = new Array( 'http://images.wikia.com/alicesoft/images/thumb/d/da/Sengoku_Rance_-_logo.gif/200px-Sengoku_Rance_-_logo.gif', 'http://images.wikia.com/alicesoft/images/c/cd/Tsumashibori_-_logo.gif' 'http://images.wikia.com/alicesoft/images/c/cc/Double_Teacher_Life_-_logo.gif' 'http://images.wikia.com/alicesoft/images/f/fb/Beat_Angel_Escalayer_-_logo.gif' );

addOnloadHook(logochangerscan);

function logochangerscan{ for (i = 0; i < miniwikis.length; i++){ if (wgTitle.search(miniwikis[i]) != -1) { logoChange(i); break; }   } }

function logoChange(idx){ var linkA; switch(skin) { case 'monobook': linkA = document.getElementById('p-logo').getElementsByTagName('a')[0]; linkA.parentNode.style.textAlign = 'center'; var imgA = linkA.appendChild(document.createElement('IMG')); imgA.src = monologos[idx]; break case 'quartz': linkA = document.getElementById('wikiLogoLink'); var imgA = linkA.appendChild(document.createElement('IMG')); imgA.src = quartzlogos[idx]; imgA.setAttribute('style', 'margin-left:60px;'); break default: return; } }

/* */