I’m mostly writing this down so I remember it, but maybe it’ll also come in useful to other people. This is how I converted from LJ to WordPress.
Getting data out of LJ
WordPress’s LiveJournal importer is buggy and doesn’t do a bunch of stuff I want (such as re-writing links to my own posts so that they now point to the new blog). Luckily, jwz has been here before, and wrote a Perl script to download a journal and output WordPress’s XML import/export format. This does better, but needed a bit of hacking to suit my obsessive need to avoid information loss in the transfer to WP. I’ve stuck my own version here: the comment at the top describes what I changed. You’ll need LJ::GetCookieSession. Like all Perl scripts, this one is configured by global variables near the top, so you’ll need to change those too. You then say
ljgrabber.pl -v --wordpress --comments > wordpress.xml
and then upload wordpress.xml to the WordPress importer (Tools, Import on the WordPress dashboard).
Note that I haven’t used any of the other advertised options (to re-write bits of your LJ so they point to the new blog) in my modified version of the script, so damned if I know whether they work, crash, or delete your journal. Probably best to try it on a spare journal first, I’d’ve thought.
I ran through WordPress’s famous 5 minute install having stuck the untarred WP download in the right place on my site. Excitingly, this left wp-config.php (which has stuff like the database password in it) with both public read and public write permissions (assuming it was the installer and I wasn’t immediately pwned by something before anyone had seen the blog). So, you might want to watch for that.
Plugins you will want
- Akismet: WordPress blogs attract a lot of spam comments. Akismet kills them all. Possibly there’s something I can do about this to make my blog less obviously a WordPress one, but I haven’t worked out what they’re using to identify it yet.
- Avalicious will grab user pictures from LJ if your commenters specify a LiveJournal as their website URL. Since jwz’s Perl script produces such comments, installing this gets you the familiar looking icons for everyone. Note that you will want to apply jwz’s patch or it’ll kill your performance on pages containing comments from people who deleted their journals.
- Live Comment Preview: cos it’s handy.
- Subscribe to Comments: nearest thing I’ve found to LJ’s email functionality. I’m not sure whether it’s actually emailing you replies to your comment or just any new comments. Probably should check that.
- LiveJournal Crossposter: does what it says on the tin. Note that if you go back and edit imported posts, it seems to want to post them again (presumably because the imported posts don’t have whatever magic it uses to tell that they’re already posted to LJ), but for posts which it has cross-posted for you, it’s clever enough to apply subsequent edits back to LJ, too. Note that there’s a setting which controls whether it just posts excerpts or the whole entry. For now, I’ve set it to the whole thing, even if it does mean the Russian mafia are getting advertising revenue from my writing.
- Updraft Plus Backup/Restore: backs up the database and files to Google Drive, which I wasn’t using for anything else.
- WP Super Cache: Crimefighting Jesus told me to, and he runs the hosting company, so he should know.
I expect I’ll tart it up a bit at some point but the default theme seems reasonable enough for now. Any other top tips welcome, I guess.