It’s been almost a year and a half since WordPress 2.9 came out, and I recall being excited as usual as I readied the admin page’s “automatic update” function on his website. Then, things ground to a halt and I was coldly informed that my version of MySQL, 4.0.2 or something of the sort, was too old to support WordPress 2.9.

I contacted this website’s host to see if they could migrate my 4.0.2 SQL database to 5 for me, dryly reminding them that when I built the blog back in 2007, it was on their own pages that they recommended choosing 4 instead of 5 because it was “well-tested and stable” instead of version 5 which was apparently scary and new for everyone back then. My host refused, telling me that I’d need to use phpMyAdmin to manually back up everything in my blog (a rather large 16 MB pile of text in SQL format; it takes Notepad 3 minutes to open it) and then reimport it into a new version 5 MySQL database.

That was back in February 2010, and thanks to lots of other irate users suffering from the same issue, there was no shortage on instructions for doing some SQL database tweaking. However, no one else seemed to have my problem, which was that re-importing into MySQL 5 destroyed all of my Arabic characters and replaced them with garbage text. Stymied, irritated, and in the process of getting ready for my trip to Egypt the following month, I decided just to stick with WordPress 2.8.6 until I got around to figuring out how to fix the problem.

Fast-forward to now. Sony, Sega, Nintendo,, Bank of America, and dozens of other big-ticket websites are being hacked on a regular basis, and script kiddies (talentless hackers who use pre-made scripts to hunt for websites with vulnerabilities, instead of doing the research/attack on their own) are coming out of the woodwork to infest any website they can with Trojan downloaders to ensnare people using Google and Google Image Search.

Over the past few weeks, I’ve winced as I’ve read these articles and thought of my own poor, dust-collecting I’m not so vain that I think that any hacker would actually target my site directly (if I was that shallow and self-centered/boring, I’d just use Twitter and tell you what I was eating for lunch and how cute my nonexistent cats are), but it would be simple for a coder to just use scripts to scan the internet for websites using outdated versions of WordPress. WordPress is, you have to remember, the most famous and widely used Content Management System in the world, and just like the Windows operating system, is a fat and juicy target for the sharks out there. If my site was discovered in an automated search like that, I didn’t want to be the unlucky discoverer of a remote takeover security hole, and own up to the embarrassment of not practicing what I’ve preached for years to friends, family, and students: I haven’t kept my blog software up to date.

That was this morning. I’m pleased to say I’m writing this to you from a brand-new database on a freshly upgraded copy of WordPress 3.1.3. It probably doesn’t – and shouldn’t – look any different to you. All of the improvements have been made on the administrative side of things, or deep within the system code to hopefully batten down the hatches. What was the fix I finally discovered? This lengthy page on the WordPress Codex* explained that before WordPress 3.0, there was no function in the configuration files to ensure that the blog’s database was being stored in the universal internet character set, UTF-8, so things were probably being written as ASCII, the outdated Latin-text-only character set which no one on the internet should be using anymore (it’s 2011; global village; internet should be in all languages, etc etc). So I ran the SQL command to convert all my posts to ASCII, then into binary, and then into UTF-8 and bam…it was solved. I couldn’t believe my eyes. I backed up the fresh MySQL 5 database and the WordPress 2.8.6 files, and while holding my breath, clicked the update button that I hadn’t clicked in over a year. No halt this time…”Update has completed successfully” greeted me within 30 seconds.

So there’s a bit of a load off my shoulders. It’s past midnight now, and I’m writing this entry after spending a couple hours going through some of my favorite old entries from Jordan, like biking in the Dead 2 Red, visiting Sheikh Suliman in Ghor Safi, and of course hiking the amazing wadis with my friends. Heck, I even read through the entry I wrote right after I had reformatted this computer and put Windows 7 on it after getting infected by the W32/Sality malware. It was a well-written article.

As a final note, I did notice that although the Arabic in my posts themselves was spared – thank goodness – after updating from 2.8.6 to 3.1.3 the non-Latin characters in comments vanished, and I had to go through and correct them by hand. Thankfully there hasn’t been many, but if you happen to see anything on the site that looks like ???? ???? please let me know – that probably used to be العربية – Arabic text.

*Why didn’t I use that page back in February 2010? If you scroll down on that page, you’ll notice an author comments that the page was completely revamped in October 2010 because it had gotten so out of date. The information that could have helped me probably did not exist when I was searching right after 2.9 was released.