User:Gryphon/wowwiki.js
From WoWWiki
Note: After saving, you may have to bypass your browser's cache to see the changes.
- Mozilla / Firefox / Safari: hold down Shift while clicking Reload, or press Ctrl-Shift-R (Cmd-Shift-R on Apple Mac)
- Internet Explorer: hold Ctrl while clicking Refresh, or press Ctrl-F5
- Konqueror: simply click the Reload button, or press F5
- Opera users may need to completely clear the cache in Tools→Preferences.
/*-Navigation
Adds Wiki in-house search below Google Search
*/
addOnloadHook( function() {
var googleSearch = document.getElementById('p-search').innerHTML.replace("Search", "Google Search");
var wikiSearch = "<h5><label for='searchInput'>Wiki Search</label></h5><div id='searchBody' class='pBody'><form action='/index.php?title=Special:Search' id='searchform'><div><input id='searchInput' name='search' value='' type='text'><input name='go' class='searchButton' id='searchGoButton' value='Go' type='submit'> <input name='fulltext' class='searchButton' id='mw-searchButton' value='Search' type='submit'></div></form></div>";
document.getElementById("p-search").innerHTML = googleSearch + wikiSearch;
});
/*-Footer
Replaces footer contents with jump to top
*/
addOnloadHook( function() {
document.getElementById("footer").innerHTML = '<a href="#top" title="">↑ Jump to the top ↑</a>';
});
/* [[Category:User:Gryphon|wowwiki.js]] [[Category:User JS|Gryphon]] */
