Page 6 of 36

Previous page Photo of the Week, part 2

Paddling Lake Superior
If you’ve clicked-through from my photo on, welcome! Click here to see a larger version.

Some other links that might interest you:

Happy holidays!

I'm in Rails

I’ve made a code contribution to Ruby on Rails. It was minor, but I’m glad I could help. See ticket 10435 and changeset 8386.

Supposed to get some rain today…keeping my fingers crossed.

Update 2007-12-17: Looks like my patch made it into Rails 2.0.2. And we did get that rain, but more would be good.

Update 2008-03-17: I managed to get another small patch committed. Go open source!

Heat Wave

“It was summer in December, blowing heat waves in my mind…”
— Colin Hay, Are You Lookin’ At Me?

I think that line was meant to give you a feel for how unusual the southern hemisphere seasons must feel to those of us up “on top.” But whether you’ve been below the equator or not, it hasn’t been hard to get a feel for austral summer in South Carolina lately. It reminds me of being in Sydney in December years ago. Yesterday the temperatures here hit the mid 70s. I’ve seen that in December before in the years I’ve lived in SC. But I don’t recall a December forecast like the one I saw this morning. Highs of 76°F for the next three days, then 72 and maybe some rain (please!) on Thursday, and then the cold rolls in on Friday, only a high of 67.

Having grown up north of here, I guess I have a mindset that it’s supposed to be cold for the holidays. And usually it is somewhat cold in upstate SC for December. But it’s hot out and we should be kayaking instead of Christmas shopping!

Formatting a Javascript Date for MySQL

I don’t like to code in JavaScript, but that’s the Ajax-y wave of the future. So I write it when I have to. This week I needed to format a Javascript date as a MySQL-style date like 2007-12-08.

JavaScript apparently doesn’t have a nice date formatting function or even a generalized sprintf. Another Javascript quirk is that the Date.getMonth() function returns 0-11, while the getDate() function returns 1-31. I’m not sure what the designer was thinking on that one.

I came up with this function…feel free to use it in your code with or without credit:

function formatDate(date1) {
  return date1.getFullYear() + ’-’ +
    (date1.getMonth() < 9 ? ‘0’ : “) + (date1.getMonth()+1) + ’-’ +
    (date1.getDate() < 10 ? '0’ : ”) + date1.getDate();

Comet Holmes

Comet 17P/Holmes
I’ve been reading about Comet 17P/Holmes on SpaceWeather. Last night I finally went out to have a look. Once I was out of range of our annoying streetlight and the neighbors’ lighting, I was able to pick the comet out with the naked eye. It’s just a smudge in the sky, but apparently that smudge is bigger than the sun.

I got my camera gear out and braved the cold to take a few photos. This one turned out OK. Now I just need a telescope and clock drive to take pictures like this.

Next page