WordPress.org

Ready to get started?Download WordPress

Forums

My Calendar
Event Times are Wrong in iCal (3 posts)

  1. jmiertschin
    Member
    Posted 2 years ago #

    Hi - When I export my event to iCal the event times are wrong. It seems they are pushed forward 5 hours. In other words an event that is supposed to start at 10 AM starts at 3 PM. Anyone able to help?

    I have tried changing the timezone settings for iCal, for my-calendar, and for WordPress and can't seem to get any results. Not sure what controls this. Thanks so much for your help.

    http://wordpress.org/extend/plugins/my-calendar/

  2. David July
    Member
    Posted 1 year ago #

    I just noticed the same behavior. You can observe the time differential in the array included at the start of the ICS file.

    [ical_start] => 20121110T110000
    [ical_end] => 20121110T190000
    [dtstart] => 2012-11-10T07:00:00
    [dtend] => 2012-11-10T15:00:00

    WordPress is set to "New York" which is currently GMT-4. For whatever reason, "ical_start" and "ical_end" are using GMT with no offset for time zone while "dtstart" and "dtend" are correct.

    For what it's worth, a similar differential appears in the ICS file downloadable from the sample calendar.

    [ical_start] => 20101204T140000
    [ical_end] => 20101204T050000
    [dtstart] => 2010-12-04T09:00:00
    [dtend] => 2010-12-04T00:00:13

  3. David July
    Member
    Posted 1 year ago #

    In order to get the downloaded iCalendar times correct, I made the following changes as a workaround.

    .\my-calendar-export.php

    Line 41
    REPLACE DTSTAMP:{ical_start}
    WITH DTSTAMP:{dtstart}

    Line 43
    REPLACE DTSTART:{ical_start}
    WITH DTSTART:{dtstart}

    Line 44
    REPLACE DTEND:{ical_end}
    WITH DTEND:{dtend}

    .\my-calendar-ical.php

    Line 13
    REPLACE DTSTAMP:{ical_start}
    WITH DTSTAMP:{dtstart}

    Line 15
    REPLACE DTSTART:{ical_start}
    WITH DTSTART:{dtstart}

    Line 16
    REPLACE DTEND:{ical_end}
    WITH DTEND:{dtend}

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic