From 9e6d97f106433b1d6f322d8473e925b7e6fddc8f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Lehrke?= Date: Thu, 19 Nov 2009 07:52:42 +0000 Subject: [PATCH] Fix VTZIMEZONE DTSTART Issue --- calendar/inc/class.calendar_ical.inc.php | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/calendar/inc/class.calendar_ical.inc.php b/calendar/inc/class.calendar_ical.inc.php index 0c7df96a3d..ae0b8f1580 100644 --- a/calendar/inc/class.calendar_ical.inc.php +++ b/calendar/inc/class.calendar_ical.inc.php @@ -245,6 +245,13 @@ class calendar_ical extends calendar_boupdate // --> we have to parse it and let Horde_iCalendar add it again $horde_vtimezone = Horde_iCalendar::newComponent('VTIMEZONE',$container=false); $horde_vtimezone->parsevCalendar($vtimezone,'VTIMEZONE'); + // DTSTART must be in local time! + $standard = $horde_vtimezone->findComponent('STANDARD'); + $dtstart = $standard->getAttribute('DTSTART'); + $standard->setAttribute('DTSTART', date('Ymd\THis', $dtstart), array(), false); + $daylight = $horde_vtimezone->findComponent('DAYLIGHT'); + $dtstart = $daylight->getAttribute('DTSTART'); + $daylight->setAttribute('DTSTART', date('Ymd\THis', $dtstart), array(), false); $vcal->addComponent($horde_vtimezone); $vtimezones_added[] = $tzid; }