Simon Willison’s Weblog

Subscribe
Atom feed for time

3 items tagged “time”

2024

Storing times for human events

Visit Storing times for human events

I’ve worked on various event websites in the past, and one of the unintuitively difficult problems that inevitably comes up is the best way to store the time that an event is happening. Based on that past experience, here’s my current recommendation.

[... 1,676 words]

2009

Making the HTML5 time element safe for historians. PPK presents a detailed history of dates and calendars and points out that the HTML5 time element is ill prepared to faithfully represent the kind of dates historians are interested in.

# 6th April 2009, 2:01 pm / calendars, dates, datetime, historians, history, html5, ppk, standards, time

2007

calendar.timegm() (via) An “unrelated but handy function” that converts a time.gmtime() in to a corresponding Unix timestamp. I’ve been hand-rolling this one for years; never thought to look in calendar.

# 3rd September 2007, 1:54 am / calendar, datetime, python, sam-ruby, time, timezones, unixtimestamp