Skip to content

Commit

Permalink
Time zone set Europe/Central for iCalendar export
Browse files Browse the repository at this point in the history
  • Loading branch information
michal6103 committed Dec 10, 2011
1 parent 08f0f04 commit 32de843
Showing 1 changed file with 17 additions and 1 deletion.
18 changes: 17 additions & 1 deletion app/views/events/show.ics.erb
@@ -1,6 +1,21 @@
BEGIN:VCALENDAR
VERSION:2.0
PRODID:-//iCalendar export//EN
BEGIN:VTIMEZONE
TZID:Europe/Central
BEGIN:STANDARD
DTSTART:19710101T030000
TZOFFSETFROM:+0200
TZOFFSETTO:+0100
RRULE:FREQ=YEARLY;BYMONTH=10;BYDAY=-1SU
END:STANDARD
BEGIN:DAYLIGHT
DTSTART:19710101T020000
TZOFFSETFROM:+0100
TZOFFSETTO:+0200
RRULE:FREQ=YEARLY;BYMONTH=3;BYDAY=-1SU
END:DAYLIGHT
END:VTIMEZONE
BEGIN:VEVENT
UID:<%= @event.id %>@<%= request.host %>
SUMMARY:<%= @event.title %>
Expand All @@ -9,8 +24,9 @@ LOCATION:<%= @event.venue_address %>
URL:<%= custom_url_for @event %>
STATUS:CONFIRMED
CLASS:PUBLIC
TZID=Europe/Central
DTSTART:<%= @event.start_at.strftime('%Y%m%dT%H%M%S') %>
DTEND:<%= @event.end_at.strftime('%Y%m%dT%H%M%S') %>
DTSTAMP:<%= @event.start_at.strftime('%Y%m%dT%H%M%S') %>
END:VEVENT
END:VCALENDAR
END:VCALENDAR

0 comments on commit 32de843

Please sign in to comment.