If you will be traveling and need offline access to your Mediawiki wiki, what should you do?
If you need to grab pages from a wiki that you aren’t the administrator of, you can try running a web crawler on it or try this Google Gears hack.
But if you are the administrator of the wiki (or you know the admin) you can make a Mediawiki2HTML dump. There is a Mediawiki extension that does it for you. Here’s how to run it:
fetch the DumpHTML extension with shell commands like so:
cd /whatever/mediawiki/extensions
svn checkout http://svn.wikimedia.org/svnroot/mediawiki/trunk/extensions/DumpHTML
run a shell command something like this as a cron job (create the appropriate folders first)
#!/bin/sh
# Generate a new html dump of wiki.orbswarm.com LCS 8-17-08echo “deleting contents of /home/swarm/wiki.orbswarm.com-html”
rm -rf /home/swarm/wiki.orbswarm.com-html# DumpHTML.php expects to be run from the maintenance directory. The skin won’t get HTMLified if you run it from another directory
cd /home/swarm/wiki.orbswarm.com/extensions/DumpHTML
/home/swarm/php5/bin/php dumpHTML.php -d /home/swarm/wiki.orbswarm.com-html -k monobook –image-snapshot –force-copyecho “deleting /home/swarm/wiki.orbswarm.com/offline/*”
rm -rf /home/swarm/wiki.orbswarm.com/offline/*/bin/tar -czf /home/swarm/wiki.orbswarm.com/offline/swarm-wiki-html.tar.gz /home/swarm/wiki.orbswarm.com-html/
The way the above script is set up, every day, the .gz file is placed in a web accessible folder. I can then download it before I go on my trip.

September 2nd, 2008 at 5:00 pm
A new (slightly modified) version of DumpHTML is robust against character-encoding problems because it saves articles and media files with MD5 hashed filenames instead of double-byte encoded unicode. See http://www.mediawiki.org/wiki/Extension:DumpHTML and download a patch from https://bugzilla.wikimedia.org/show_bug.cgi?id=8147 .
September 3rd, 2008 at 9:18 am
Thanks Tom. I had run into the long-filename problem myself. My workaround was to change the single very-long-filename to a shorter filename. I’ll wait a while and hopefully your patch will be in the next version of dumpHTML (for all my nerdiness, I find the patch command a bother to use).
Thanks