User:Joeytje50/searchfix.js

//This script fixes the search for the Wikia skin, to go to the page immediately if it exists.

function fixSearchbar { if ($('#WikiaSearch').length) { $('#WikiaSearch button.secondary').attr('name','go').val('Go'); } } addOnloadHook(function {	var fixSearchInterval = setInterval(function { if ($('#WikiaSearch button.secondary').val != 'Go') { fixSearchbar } else { stopFixSearchInterval }	},200)	function stopFixSearchInterval {		clearTimeout(fixSearchInterval)	} })