Several clients do not support custom timezone information.

This iCal export incorrectly reports UTC times when imported into Google, iCal, Outlook.

BEGIN:VCALENDAR
VERSION:2.0
METHOD:PUBLISH
X-WR-CALNAME: *
PRODID:-//Drupal iCal API//EN
BEGIN:VEVENT
UID:calendar:140:field_date:0:0
SUMMARY:Faculty and staff meeting
DTSTAMP;TZID=America/Detroit;VALUE=DATE-TIME:20100330T122326
DTSTART;TZID=America/Detroit;VALUE=DATE-TIME:20100402T081500
DTEND;TZID=America/Detroit;VALUE=DATE-TIME:20100402T093000
URL;VALUE=URI:https://*/node/140
END:VEVENT
END:VCALENDAR

Please change the export to use UTC (Z) timezone.

BEGIN:VCALENDAR
VERSION:2.0
METHOD:PUBLISH
X-WR-CALNAME: | Open Atrium for Broad College of Business at Michigan State University 
PRODID:-//Drupal iCal API//EN
BEGIN:VEVENT
UID:calendar:140:field_date:0:0
SUMMARY:Faculty and staff meeting
DTSTAMP:20100330T162326Z
DTSTART:20100402T121500Z
DTEND:20100402T133000Z
URL;VALUE=URI:https://*/node/140
END:VEVENT
END:VCALENDAR
CommentFileSizeAuthor
#2 diff.patch1.58 KBhawleyal

Comments

hawleyal’s picture

Title: iCal events export incorrectly, do not use UTC (Z) timezone » iCal events export incorrectly, switch to use UTC (Z) timezone

changed title

hawleyal’s picture

Status: Active » Needs review
Issue tags: +patch
StatusFileSize
new1.58 KB

Patch!
Change: force UTC timezone
Calendar: 6.x-2.x-dev (2010-Feb-28)

  • Change the timezone to UTC for the events in the theme include
  • Forces UTC timezone in the template
hawleyal’s picture

skwashd’s picture

I have been working on RFC 2445 compliance, I have submitted #760316: calendar_ical isn't RFC compliant which deals with this issue, and some others. I'd welcome any feedback.

stephenhendry’s picture

subscribe

presleyd’s picture

This patch worked perfectly for me in Outlook and Thunderbird/Lightning

raintonr’s picture

+1 Subscribing

edonnelly’s picture

Patch #2 worked beautifully. iCal feeds had been ok for some programs (e.g., Google Calendar) but not others (Outlook, for one, kept having times off by one hour). All seems perfect now. Thank you so much.

presleyd’s picture

@skwashd, do those two patches of yours #760284: template_preprocess_date_vcalendar needs to be changed to help calendar_ical be more RFC 2445 compliant and #760316: calendar_ical isn't RFC compliant solve this? Can this be marked as a duplicate? I guess I could test those two tomorrow and find out myself though...

skwashd’s picture

@presleyd I would mark this one as a dupe and use #760284 and #760316. I need to reroll #760316 to fix an issue I identified in the comments - I'd forgotten all about that. I'll try to fix it tonight.

arithmetric’s picture

Issue tags: -patch

The patches in #760284 and #760316 did not solve the compatibility problem I experienced with Outlook (imported events are displayed one hour later than they should). Adding the patch from this issue did fix it.

Since it looks like this patch may be marked as a duplicate of the other two, I've integrated the changes from this patch into the patch in #760316 in this comment:
http://drupal.org/node/760316#comment-3535008

karens’s picture

Status: Needs review » Closed (duplicate)

I'm trying to sort through all the ical patches. Since this has been consumed into another one of the patches, let's get it off the list.