User:AT/WikiSwap

What is it?
WikiSwap is a small extension that adds a "Switch" tab to your interface. This allows you to view your current page, but in the other wiki ( GWW -> GuildWiki, or GuildWiki -> GWW )

Ok... Why?
Mostly laziness, as I was spending way too much time switching between wikis, checking if stuff could be ported or had to be done from scratch. There could be potential uses for admins of both wikis ( checking if vandal on GWW = vandal on Gwiki, for instance ) but that was more of an afterthought.

How?
To use it, simply add this to your monobook.js:

Then save the page, and perform a hard refresh (Ctrl-F5 in Firefox)

GuildWiki
As GuildWiki is changing its default skin over to Monaco in the near future, the above instructions won't work soon. JediRogue has kindly ported WikiSwap over to monaco, instructions for use are here.

Source

 * Functions used by WikiSwap: User:AT/wikiswapfuncs.js
 * Wikiswap: User:AT/wikiswap.js

Bugs

 * Subpages are treated as the full pagename. i.e. "wiki.guildwars.com/wiki/User:AT/WikiSwap" becomes "gw.gamewikis.org/wiki/WikiSwap" Fixed with v0.2
 * Only first section of an IP address is counted. i.e. "127.0.0.1" becomes "127". Fixed with v0.2

Stuff to do

 * Implement auto-detection of which wiki is being used - See v0.3
 * I'm pretty much failing at seperating the libraries used from the actual WikiSwap function, so it will add quite a bit of code. If anyone can help with this, I'll love em :) Finished
 * Test on GuildWiki
 * Deal with the following:
 * Switching from Guild_Wars_Wiki namespace to GuildWiki namespace (i.e. Guild_Wars_Wiki:Policy to GuildWiki:Policy)
 * Switching from Guild namespace - tab should not be available as there is no Guild namespace on GuildWiki.

v0.4 (current)

 * Added basic support for Guild Wars Wiki: and GuildWiki: namespaces.

v0.3

 * Now auto-detects which wiki is being used and switches accordingly
 * Changed tab so it's a bit less intrusive

v0.2

 * Rewrote getURL function so it can handle IPs and Subpages.
 * Variable to choose GWW -> Gwiki or  Gwiki -> GWW.

v0.1

 * simple switch, GWW -> Gwiki only.