When I started researching on interacting with Google calendar API, I came across a cool feature offered by this API, and that is the event gadgets.
Although the calendar UI is quite fixed and developers can’t do much to extend it, Google did leave the door open for some extensions using this feature.
Event gadgets are like any other event on the user’s calendar, but how it looks is mostly up to the developer. It will appear as an icon on that event day, and when clicking on it, it will open an iframe which will show any given URL. The size of this iframe is also configurable.
To set it up using the .NET API library, simply create an event object and set the WebContentLink properties:
WebContentLink conetentLink = new WebContentLink();
conetentLink.Title = “Buy tickets”;
conetentLink.Type = “text/html”;
conetentLink.Url = “http://myserver/tickets.aspx?show=hair”;
conetentLink.Icon = “http://myserver/money-icon.jpg”;
conetentLink.Width = 200;
conetentLink.Height = 100;
The contect can be either images, HTML pages, or igoogle gadgets.
In Birthdays Synchronizer, I used this feature to create the birthday reminders on the users’ calendar. When the event is created, the friend name and picture URL are saved as part of the parameters on the gadget link, allowing my hosted page to show this information nicely to the user:
Well.. maybe it does require a little more work on the UI :)