Created
November 3, 2017 08:47
-
-
Save Vusys/7578db85e984268a0ab7b212acbf7854 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ==UserScript== | |
// @name Wikia Monobook | |
// @include *.wikia.com/* | |
// @grant none | |
// ==/UserScript== | |
(function() { | |
var loc = window.location.toString(); | |
if(loc.indexOf('useskin=monobook') === -1){ | |
location.replace(loc + (loc.indexOf('?') === -1 ? '?useskin=monobook' : '&useskin=monobook' ) ); | |
} | |
var a = document.getElementsByTagName('a'); | |
for (var i = 0; i < a.length; ++i){ | |
if(a[i].href.indexOf('wikia.com') === -1){ | |
continue; | |
} | |
a[i].href = a[i].href + (a[i].href.indexOf('?') === -1 ? '?useskin=monobook' : '&useskin=monobook'); | |
} | |
})(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment