get in touch
No. 92
May 22nd, 2008

Check Out My New Company
You Know You Want To


WordPress Upgrade Tips

As many of you know, I heart WordPress. It’s robust, phenomenally easy to customize, and with all of the contributions from the open-source community, “tech support” is never hard to come by. With a few tweaks to the default settings, it’s also quite SEO-friendly. Perhaps best of all, it’s so easy for clients to use that I’ve started building a number of sites completely using WordPress as a content management system.

One of the few downsides to the platform is the cumber-some-ness (how’s that for onomatopoeia?) of upgrading to the latest version. Matt Mullenweg et al just released WordPress 2.5.1 a few weeks ago, and upgrading is something I highly recommend that everyone do based on some recent spam injections I received on my own blog, which ran the previous version. I know there are a few automatic WordPress upgrade plugins out there, but I’m hesitant to automate a process that seems to vary by server and by client.

So after upgrading about nine instances of WordPress in the last week, here are a few tips I’d recommend to folks (lots of these are in the official upgrade instructions, but bear repeating):

1) Absolutely make a backup copy of your database and all of the folders in your WordPress directory. Note: you can easily export your WordPress mySQL database using phpMyAdmin, assuming your webhost has that installed. Even if you don’t think you’ve made any tweaks to core WordPress files, it’s still a good idea to download all of them from your server into a local folder on your computer using FTP.

2) Disable all plugins before removing/changing any files on your server. Note: If you forget to do this, and it looks like your blog has broken after the upgrade, you CAN safely remove these from the plugins folder via FTP and it will have the same effect.

2a) Note: if you are on a Rackspace server (a terrific company btw; I highly recommend them if you can afford their pricetag), you may have to physically remove all plugins from your wp-content/plugins folder, and then re-upload them after the upgrade process is complete. The admin panel may not load otherwise.

3) DO NOT TOUCH YOUR “wp-content” FOLDER AT ALL DURING THE UPGRADE PROCESS. TAKE SPECIAL CARE NOT TO OVERWRITE IT WHEN UPLOADING NEW FILES. The reason is that any customizations you made to your theme, be it “default,” or a custom theme that you downloaded, will be overwritten & your blog will look completely different. There’s nothing in there that you need to change anyway.

4) If you’re upgrading from version 2.3 or earlier, you might see some funky characters in your posts like ’. These are simply mis-interpretations of apostrophes and quotation marks. They come from a new line in the wp-config.php file that specifies a charset. YOU DON’T HAVE TO GO IN AND EDIT YOUR POSTS (which I started doing before I found the solution).

In your wp-config file, find the lines:

define(’DB_CHARSET’, ‘utf8′);
define(’DB_COLLATE’, ”);

Just change the first one to

define(’DB_CHARSET’, ‘′);

And those weird characters should go away 🙂

Anyone else have WordPress upgrade experiences they’d like to share?