Skip to content

Categories:

Enhanced hCalendar download links

Introduction

A script that automatically transforms links to Technorati’s events service into a useful little menu allowing events to be downloaded or added to various online calendar services. If you want to see it action check out this live demo.

It’s a bit rough around the edges (there’s a list of issues below). It uses Dan Webb’s Sumo microformats parser to extract event details (some online calendar services don’t support iCalendar import, so the details need to be passed directly) and JQuery to manipulate the page.

Files

The latest version of the script is kept in a public repository on GitHub

How to use

  1. Mark up your events using hCalendar
  2. Add a link to Technorati’s events parsing service. For example, the link for this page would be http://technorati.com/events/http://blog.georgebrock.com/projects/enhanced-hcalendar-downloads
  3. Add all the relevant Javascript files to your page (Sumo’s microformat.js and hcalendar.js, JQuery and enhanced-hcalendar-downloads.js)
  4. That’s all you need to do, but you might want to add some CSS rules to make the menu prettier (start here: enhanced-hcalendar-downloads.css)

Issues

  • The current version only supports duration in the format PTminutesM. If a dtend is provided it will be used in preference to duration.
  • Sumo and Technorati both have some quirks about which variations of the ISO 8601 date format they support.
  • If you include a fragment in the URL you pass to Technorati, the script will use the first event found in that container to generate the Google and Yahoo! calendar links. Unfortunately the Technorati service will ignore the fragment and parse all the hCalendar instances on the page, I’ve asked them if this can be changed.

Posted in projects. Tagged with , , , , , , .

0 Responses

Stay in touch with the conversation, subscribe to the RSS feed for comments on this post.

Some HTML is OK

(required)

(required, but never shared)

or, reply to this post via trackback.