Category Archives: Blogging

No More Strangeness

It took a little bit of effort but the stange characters that WordPress was displaying through a significant number of posts have now been removed.

I went looking briefly about what might have caused the problem and can confirm that it is related to the character encoding in MySQL. There are numerous posts in the official WordPress support forums and on blogs dating back to 2006 – so it isn’t a new problem at all.

After removing them from the site, I’ve subsequently verified that the database encoding is UTF-8 and WordPress is publishing in UTF-8 according to the content type in the meta data. That makes me think that those strange characters could have been present in my site from an earlier upgrade of WordPress and I’ve just never noticed it before.

I think this might be karma for not doing enough housekeeping on my site.

Strange Characters

Strange non-ASCII characters being inserted into WordPress postsWhile reviewing a swag of older posts tonight, I noticed some strange characters throughout my posts.

The strange characters were not something that I’d have put there, they don’t make sense and are rather random. Some of them there is a pattern to, for instance a single quote seems to be consistently replaced with three different characters.

At a guess, it looks to be some sort of an encoding problem. I doubt that it’ll be a problem with WordPress itself as it multi-lingual capable, so it’ll probably be something to do with the rich WYSIWYG editor that WordPress uses or possibly a database encoding issue.

2008 Blogging Statistics

Matt Mullenweg and Alex King have posted some blogging statistics again in their respective end of year posts. Being an curious kind of chap, I wondered what my own blogging habits have been over the years.

POSTS AVG. POST LENGTH TOTAL POST LENGTH COMMENTS AVG. COMMENTS
2004 1 478 487 0 0.0
2005 82 1949 159835 511 12.7
2006 103 1837 189259 865 4.5
2007 127 1977 251150 229 1.0
2008 68 1597 108623 78 0.6

The longer posts are typically caused by rants to do with things like Australian Idol, which coincidentally also tend to generate a lot of comments. The higher frequency of posting in the past has also been made up of technical style posts, which after realising I had a bit of a split personality – I have moved over to #if debug.

For those that are interested in doing the same, I have modified the SQL that Alex used initially to generate his results so that it’ll collate the blogging statistics for all years at once. Computers are good at computing and laziness is a virtue of a programmer.

Web Statistics

Matt Cutts, a prominent Google engineer has been posting an overview of the web statistics that his blog receives for the last few years. I certainly can’t compete with the staggering amount of traffic his site takes, however I thought it might interest a few people. In the next day or two, I’ll be writing three short posts highlighting this sites web statistics since 2006 in a yearly format.

Bad Luck & Poor Timing

My run of bad luck continued tonight as I went to upgrade WordPress on #if debug.

I backed up the database, downloaded a copy of the source files and set about uploading WordPress 2.7 – only to have the power go out twice during the event. That not being enough, I happened to pick a time to perform an upgrade when my web host scheduled my server for maintenance. This was completely my fault, I received an outage notification – I just thought I’d get it all done before the outage window began and I would have if it went to plan like normal.

After I finally got everything successfully uploaded, or at least I thought I had, I was then unable to ‘upgrade’ as the script would terminate without an error and without completing. That resulted in the web site working when you’re browsing it but wouldn’t allow me to login to the admin area – as it kept requiring me to complete the upgrade.

I assumed that the power outage that was the root cause of it – leaving one of the core WordPress files in an incomplete state. I deleted all of the core WordPress files from the server and starting clean and the upgrade of WordPress was then fast and painless.

I still find it amazing that I could be struck by another bit of bad luck, albeit very small and through my own fault walk into a wall – of bad timing.