Migrating from wordpress.com to .org – customisation

I’ll cover the customisation I did to the new blog in the context of two areas: templates/themes and plugins/widgets.

Templates/themes

In wordpress.org, adding a new template is simply a case of finding one, downloading it, then uploading it to the wp-content/themes directory. It is then immediately available under the Presentation option in admin.

There’s not really much else to say other than I went here to look for themes. And here to read up on them. Of course, there are many, many more available than you get on wordpress.com and you have full control of their customisation without having to pay to edit the CSS! Look out for themes that support widgets if you are used to using them.

Plugins/Widgets

Widgets are pretty big on wordpress.com blogs, and the good news is that they are supported on wordpress.org as well, that is as long as the theme you are using supports them. There are also a lot more available. There is a list of widget aware themes and third party widgets here.

Widgets are delivered as plugins which are simply uploaded into the wp-content/plugins directory. You then have to go to the plugins tab in admin to activate them. You will want to activate the Sidebar Widgets plugin whilst you are there.

You should then see the Sidebar widgets option under the presentation tab as you are used to in wordpress.com.

It is worth noting that the Askimet comment spam plugin is available as part of the 2.1 package. However to enable it you need a wordpress.com API key. As you are reading this you are probably moving from wordpress.com so handily you already have one. Just go to Users then Your Profile on your old blog and you should see the API key listed. There’s also a Google seach and del.icio.us widget present by default.

The only other plugins/widgets I’ve installed so far are covered in the next post about feeds and stats.

Migrating from wordpress.com to .org – data migration

This post covers the my experiences of data migration from wordpress.com to a self-hosted wordpress.org blog.

WordPress supports a customised RSS based XML format known as WordPress eXtended RSS (WXR) for exporting and importing content from wordpress blogs. It also supports import from a number of other blog platforms, as covered in great detail on the wordpress codex entry.

The WXR file will contain all your posts, comments, categories and custom fields. It won’t contain your blogroll.

On the wordpress.com blog the manage option on the dashboard has an export option. From here you can generate the WXR file for import into the new blog. However, before you do, be sure to go in and delete any spam comments that Askimet has hanging around. There’s no point in transferring them and doing so just increases the size of the WXR file. I forgot to do this first time around, and ran into a PHP error which I suspect was caused by excessive attempts to allocate memory when importing. Re-exporting without the spam comments solved it.

Importing is just a case of going to the admin, manage, import option on the new blog and browsing to the WXR file.

My posts on the old blog were all made by a user with the name “Adrian Spender” and userid aspender. On the new blog the userid was admin. On importing this didn’t appear to cause any problems. However it did mean that new posts appeared to be from a different user to the migrated ones. To solve this I created a new user with the same name (but as it happens a different userid) I’d suggest that before importing you create the same userid/user name user on the new blog as was on the old, and give them administrator access. I suspect this might have got around the issue I then hit.

Looking at the imported entries, and comments or pingbacks I’d made had my name linked back to the old .com blog. I had to go through and edit each comment to update the link to the new blog address to avoid inadvertantly redirecting people back to the old blog if they happened to read old comments.

The final step was to migrate over the blogroll. WordPress has a nice facility to import a blogroll from an OPML file, but unfortunately there doesn’t appear to be the equivalent export capability (at least not on wordpress.com) Thus, and as I only had a short blogroll I did it manually. If all your blogroll links happen to be in del.icio.us for example then you could create an OPML from there.

I hit the same PHP memory error when the default wordpress.org template tried to display any blogroll entry. Initially I thought this might be because I had too many, but it then happened when I pared my blogroll down to just one entry. I got around it through the subject of my next post, namely changing the template.

Migrating from wordpress.com to .org – hosting and install

I was planning to write this anyway, but Andy has prompted me to do it whilst the memory is fresh. Probably a good job as it was so easy I never had to write anything down. I’ll attempt to document it in chronological order and bring up any issues I faced as well as resources I referred to. I’ll cover the following topics in a series of posts:

  • Hosting and blog install
  • Migration
  • Customisation
  • Feeds and stats
  • Diversion strategy
  • Summary / things to do

Choosing a hosting provider

Well this wasn’t too tough. I’d heard a lot of good things about Register1.net and their Technical Director happens to frequent an online forum I visit. The only option was which package to go for. I decided to go for the VDS Pro account because of the bundled in extra features including WordPress, but I’ll come onto why that was probably an unnecessary expense.

I also registered new domains with them at the same time. This simplified and sped up the process dramatically as there were no transfers to deal with. My domains and hosting were provisioned well within an hour of ordering. I decided to bite the bullet and get .com, .net, .org, .co.uk in one go as it is common for the others to get registered by others if the original domain gets so much as noticed. In fact I also grabbed aidyspender.com, co.uk, .net and .org as well, but two of those were already with another provider and need to be moved once they are about to expire.

Access to hosting and facilities.

With my hosting, no shell access via ssh or telnet is allowed for security reasons, leaving a web interface or more usefully ftp as the main options for getting content onto the site. The VDS is hosted on Redhat Enterprise Linux, and is managed through a web interface. It is running Apache 2.0, POP3/IMAP/sendmail/virus/spam, squirrelmail, PHP 4.3.9, Perl, MyPHP 4.1.18, phpMyAdmin, analog and webalizer.

Installing wordpress.org

As mentioned, the package comes with a 1-click installation option for wordpress.org. However on inspection it was fairly back-level (1.5.1.3) compared to the current version 2.1. On reading up about the requirements I discovered that my levels of PHP and MySQL were fine for 2.1.

I then read the installation instructions, and decided it didn’t seem to much hassle to install 2.1 myself. I followed the detailed instructions which involve:

  1. Downloading and extracting the package locally.
  2. Create the database. The installation documents how to do this through phpMyAdmin. However my host doesn’t give me access to create databases explicitly through phpMyAdmin. It has to be done through their hosting web interface (I guess so they can impose limits) but this was straightforward enough. You don’t need to create any tables, or go near any SQL. You need to make a note of the database name, userid, password and hostname (usually localhost)
  3. The next step is to edit one file in the wordpress package. wp-config.php has a section which needs to be updated to reflect the database settings.
  4. Upload the files via ftp. As it is all PHP it just needs uploading to the server like any web page. No shell access is required to install. The only decision to make is where to install it. I chose to put it under the /blog directory instead of in the root of my web space so I could maintain my own index page. However wordpress itself can give you the option to have a static index page which it manages within its own CMS. I’m still happy I went with the subdir though.
  5. Run the install script, simply by loading it in your browser. It takes less than 30 seconds and asks you for the name of the blog and your email address. After that your blog is up and running!

So now I had a blog with the default theme, and the usual wordpress admin via /wp-admin. One thing that is noticeably missing is the blue header bar you get on wordpress.com with a link to the dashboard. You suddenly realise why the meta section of the template has a Site Admin entry! The admin is missing a few things you are used to on .com, notably widgets, blog stats and a few other things, but I’ll get to all that in another post. At this point the shell of my new blog was up and running.

My last.fm profile

In my increasing efforts to get with the social networking programme, I’m now signed up to last.fm. You can view my profile here. Feel free to add me as a friend.

I’m using the iScrobbler client on OS X rather than the default last.fm one as it purports to include the Last Played playlist from iTunes in its scrobblings. This is useful seen as all my music is either on the iMac, or my iPod. Hence you won’t see any updates whilst at work for example until i dock the iPod.

The range of music won’t exactly be representative of my tastes either as I’m currently in the process of re-ripping my quite substantial music collection to a lossless format (FLAC to be precise.) I think I’ll have to go through and prioritise the order they are done in. Already I am pleasantly surprised by the music Andy and Roo seem to listen to. Especially to find out that Roo is a fellow Reindeer Section fan.

Edited to add: Just discovered that iScrobbler has an option to scrobble any shared music I play. That means anything I play from my Linksys NSLU2 NAS device running mt-daapd gets logged as well. This means I can withdraw my comment about not having my full music library at my disposal!

Grand website plans

As well as providing a home for this blog, I have other plans for my new hosted space.

Obviously as a software engineer writing middleware software at IBM I spend my working day designing and developing Java. However, like most, I’ve not been able to ignore the huge amount of Web 2.0 stuff using PHP, Javascript, REST, JSON, AJAX, Rails and more. Combined with the number of APIs out there from the likes of flickr, Google, Amazon, Yahoo etc. then it is no surprise that the age of the situation application has arrived. I’ve had a bit of an introduction to some of these technologies through some work I’ve been doing over the past six months or so, but it is time to really start to educate myself.

As such I plan to use this site to start playing with this stuff, outside of the direct work environment. I have a few ideas for what I’m going to do, and REST, JSON and the flickr APIs are top of the list to start with.

For the time being, there is a rather static index page at http://www.adrianspender.com which was very quickly created using the iWeb application that ships as part of the iLife suite on Macs. All it does at the moment is link to flickr and this blog, but as I progress I’ll add links to the stuff I’m doing, as well as blogging about them here of course.

So to anybody who has made it over from the old blog, this post is my statement of intent. I’m writing this to make sure I make the time to do this stuff and you can hold me to account. I have a terrible habit of garnering huge initial enthusiasm for tasks like this which then fall by the wayside. So if you don’t see some cool stuff appearing here soon, give me a gentle nudge! If I don’t do it then I might as well have stayed at wordpress.com

This blog has moved here!

Congratulations, you’ve found the new home for Drive Through!

I’ve finally decided that as a software geek I should probably start hosting this blog myself. As such I’ve bought some hosting space from Register1 and a new domain name (well, actually the same name in .com, .co.uk, .net and .org varieties) All the content from the wordpress.com hosted site should be copied over, including comments and categories. Installation and the export/import were all very smooth. The only problem came with hitting a hosting provider limit on PHP script memory usage when importing the old site. I had a duh moment and went back to delete all the askimet spam comments which reduced the xml from 1MB to about 400k. There were no problems after that.

I’ve yet to update the template from the standard, and also add my blogroll. However what I have done is install plugins for Google Analytics and Feedburner to replace the stats which wordpress.com generates. Over time you’ll probably see a few more minor changes, including possibly adding some google adwords stuff.

I’m not planning on updating the wordpress.com version of Drive Through… any more, so to keep up to date with me from now on, please update your bookmarks to:

http://www.adrianspender.com/blog

and your feed reader to:

http://feeds.feedburner.com/drivethroughnew (or just click the feed icon your browser gives you)

I’ve yet to figure out what I need to do with the wordpress.com version of this blog. Obviously there are google and technorati search hits which will still find it, so people may still be commenting on posts there. Hence the rather obvious title to this entry which hopefully will give people the hint ;-)