Another Bike Crash

In other news, I had another acci­dent on my bike yes­ter­day. On my way home from work, a truck pulled out on me whilst on a round­about (here is a great intro­duc­tion to round­abouts for Amer­ic­ans). This ought not to hap­pen as I had right of way, but I can only assume that either the truck driver didn’t see me, or that he assumed that I was going slowly. As a res­ult, he pulled out on me; slowly because it was a big truck; and I had to swerve round him. Unfor­tu­nately he was too slow for me to get com­pletely round the back of him. With a 4 or 6 inch high kerb approach­ing, I had to turn the bike and slide it and thus me along the floor to stop.

I hit the floor hard and slid to a stop. As I got up a chap pulled my bike off the road and star­ted ask­ing if I was OK. A couple of other people kindly stopped to check too. The truck driver was, of course, long gone. My arm was badly grazed and my ribs hurt. After a couple of deep breaths, I figured they weren’t broken. Luck­ily too, my bike wasn’t dam­aged, though my shorts now have a hole, and the screen on my mobile phone is cracked and it only shows about a third of the display.

So, after thank­ing the people who had stopped, I got back on my bike and cycled the rest of the way home — I had about another 9 miles to go. By the time I got home, my ribs were hurt­ing a lot and I knew I would be off my bike again for at least a few days. That’s a real shame too as I’d just got back into doing a full 70 miles a week.

After some more hassle I won’t go into right now, Jan gave me a lift up to our local A&E depart­ment. It was busy and I ended up wait­ing for two and a half hours to see a doc­tor. He listened to my chest and decided noth­ing was broken or even cracked and that I didn’t need an x-ray. I waited another half hour to get a dress­ing on my arm and then made my way home.

I’ve had to have the day off work today, it’s quite pain­ful to move around. When I sit or stand still, it feels fine. But as soon as I move the pain kicks in. I’ll prob­ably be off work tomor­row too.

Site updates

Page Cach­ing

I’ve made some minor changes to the blog over the last few days. Firstly, I’ve been using Ricardo Galli’s WP-Cache 2.0 plu­gin. This is an effi­cient WordPress page cach­ing sys­tem. It should make the site much faster and respons­ive. WP-Cache star­ted life as the “Stat­icize Reloaded” by matt and billzeller. I like the fact that it auto­mat­ic­ally inval­id­ates the appro­pri­ate cache files when you pub­lish a post or page or comment.

It also allows you to have por­tions of you page remain dynamic. This is fant­astic. I needed my page counter to remain dynamic in order to be accurate.

Ran­dom Gal­lery Image

Someone kindly poin­ted out that click­ing on the ran­dom Gal­lery image in the side bar was open­ing up the gal­lery in the tiny little iframe still in the side­bar. Not very use­ful that. I remembered that I could include the ran­dom image dir­ectly in the side­bar, but that the code wasn’t XHTML com­pat­ible. With the cach­ing plu­gin it would also mean that the image would stop being random.

For my second tweak I ended up hav­ing to do a couple of things. One was to hack the Gal­lery code to pro­duce valid XHTML. Unfor­tu­nately the dynamic part of the cach­ing code which allows you to include a php file assumes that it needs to pre­pend ABSPATH to the include. That’s not the case for the ran­dom gal­lery image. So the last task was to tweak the dynamic part of the cach­ing plu­gin so that I could include my gal­lery ran­dom image code from an http url.

Update 21/07/2005: I’ve sub­mit­ted a trac ticket with a patch against the latest revi­sion to imple­ment this.

Speed up

I hope these changes help the site to run faster. It had been slow­ing down again. This was due to too many extern­ally gen­er­ated con­tent in the side­bars. This is all cached now so things should be much quicker.

Google Moon

On July 20, 1969, man first landed on the Moon… Those clever folks over at Google have just launched Google Moon in hon­our of that day. Google have added lunar images to their Google Maps inter­face and added in some sig­ni­fic­ant locations.

In honor of the first manned Moon land­ing, which took place on July 20, 1969, we’ve added some NASA imagery to the Google Maps inter­face to help you pay your own visit to our celes­tial neigh­bor. Happy lunar surfing.

Oh, and don’t for­get to zoom in all the way to get the really close detail!