Upgrading to WordPress 2.6

17 July 2008

Blogtender was hacked yesterday, resulting in a handfull of posts getting a list of invisible links added to the bottom, I assume in the hope that Google will pick them up. After changing my passwords (probably unnecessarily) I decided to upgrade to WordPress 2.6. The upgrade process is easy enough in theory: just back up your updated files (themes etc), delete everything, then upload the new files. Add your stuff back on, hit the upgrade.php file, and you’re done. Unfortunately I forgot to back up the database, a bad move as the upgrade wiped all my categories. Luckily all the posts were unafected, but it took a while to fix.

In case anyone finds themselves in this position, here’s what I did, bearing in mind that just beacause it worked for me doesn’t nessesarily mean it won’t screw your site up even more.

  • Connect to the WordPress database with phpMyAdmin and open up the wp_terms table.
  • Run the following sql to replace the blank category names with their id number. Without doing this you can’t easily edit the categories with the WordPress admin interface.
    UPDATE `wp_terms` SET `name` = `term_id`;
  • Now log in to WordPress and go to Manage > Categories.
  • Clicking links in the ‘Name’ column will open up the Edit Category page. Clicking the number under ‘Posts’ will show you all the posts in that category. I was able to figure out the categories based on the posts in each. Luckily I don’t have too many categories, though I did delete a couple that only had one post.

Next time I’ll be a bit more careful upgrading, and will definately make sure I have a backup of the database. I was lucky I didn’t get burnt worse than I did!

There is one comment so far. Comments are open and you can add one here.

Posted under Blogtender, Internet.

David Cumps

18 July 2008 @ 2:03 am

Had the same problems upgrading :/

Made a small post about it as well, with screenshots, in case someone reads this and want some more reference material.

Valuable lessons though, backups are holy! :p

Leave a comment:




XHTML: You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <code> <em> <i> <strike> <strong>

Recently

Upgrading to WordPress 2.6
17 July 2008

Blogtender was hacked yesterday, resulting in a handfull of posts getting a list of invisible links added to the bottom, I assume in the hope that Google will pick them up. After changing my passwords (probably unnecessarily) I decided to upgrade to WordPress 2.6. The upgrade process is easy …

Incredibly Strange Film Festival iCalendars
12 July 2008

“I am rarely happier than when spending an entire day programming my computer to perform automatically a task that it would otherwise take me a good ten seconds to do by hand.”Douglas Adams, Last Chance to See

The Incredibly Strange Film Festival is back …

Last.fm Charts
6 July 2008

This is a fun little script I wrote up that reads your weekly top albums chart from Last.fm, gets the cover art for each album, then displays the top albums on your blog. Scroll to the bottom of the page to see how it looks. …

Sharing a Canon laser printer between OSX and XP
5 January 2008

In case anyone else runs into this problem in the future, here are the steps needed to share a Canon Imageclass 4140 laser printer between OSX and XP. I’ve only tested this under Leopard, but it should work for Tiger as well.

First, the problem. While …

Archives: 2008 2007 2005

Music

Photos