Alex Pooley's Blog

Hello there, my name is Alex Pooley and I'm a freelance web developer residing in Perth, Western Australia. My passion is in the development of web sites that solve everyday problems. Here's a gallery of some of my notable work. If you need a web site designer or developer, contact me with further details. Lastly, you can read more about me.

3:30am

April 26th, 2006

Why don't you subscribe to my blog while you're here? I'm a freelance web developer and I blog about Ruby, Rails, and business online.

Go ahead and subscribe to my RSS feed. Thanks for visiting!

I woke up at 3am this morning and had no luck getting back to sleep. On the upside, I’m eating guacamole and cracked pepper crackers. MmMmmmm… Even my dog gets better sleep at night than me these days, and he sleeps all day as well.

I’m not sure if it’s insomnia keeping me awake, or I’m simply enjoying what I’m doing these days. I find my thoughts wondering to msgpad at all times of the day. It’s a unique experience and one that I hope I can keep going. I’m fascinated by Ruby, and the Ruby community also. Consider the following Ruby code:


class ActionController::TestResponse
def xhr?
self.headers['Content-Type'] =~ /javascript/
end
end

The code above is extending ActionController::TestResponse which has been defined somewhere else by Ruby On Rails, with an extra method called xhr?. I defined the above as what I saw as a natural extension to the original class. The method determines if the respone from a get/post request in a test was part of an AJAX call.

One Response to “3:30am”

  1. alex Says:

Leave a Reply

buy mp3 music uk vpn