For the last two years now this problem has been present on several websites I built where when an anonymous user clicks a date on the FullCalendar with a Google Calendar feed/field and it opens a Google Event page with the Event timestamp being in GMT (no daylight saving) timezone instead of EST (Eastern Standard Time - Toronto). This puts the Event's time ahead by 5 hours. This issue is not present if:

  1. The user is logged into the Drupal website with their account
  2. The user is logged into their personal Google account with an EST timezone set

With that said, I assume since (1) and (2) work that the issue lies with Google Calendar. For the last two years I've been checking the Google Calendar Discussion Forums for a solution off and on but I haven't found anything that works in the many threads I've come across on this issue. This has caused a lot of issues with users interpreting the Times of these Events wrong and thus missing scheduled Events. While the times shown are correct when you're visiting the actual website, it's usually when the user is on a mobile device and has to click the * (since times aren't show in responsive mode) to see the time of an Event. You can see this by shrinking the width of your browser and then clicking an asterisk (*) on the calendar.

The Calendar can be seen on two pages on the website:

I've checked the following:

  1. The Calendar Time Zone Setting set in Google Calendar (see attachment)
  2. The Drupal Site Regional Setting (see attachment)
  3. The Views Calendar Setting (see attachment)

This may be outside the scope of support for this module but I assume since a Google field is maintained and supported by this module, that someone else must have encountered this issue at some point and might have a solution or suggestion to try.

The Event's link that is generated by the View is the same whether or not you're logged in, so I assume the issue lies somewhere on Google's end.

I appreciate any suggestions/solutions.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

E Johnson created an issue. See original summary.

E Johnson’s picture

To add some more details as to what I am running.

Drupal: 7.42
Date 7.x-1.5
FullCalendar 7.x-2.0+5-dev (2013-Dec-09)
FullCalendar plugin: 1.6.5
Views 7.x-3.13

Patch #8 and the thorough explanation in #13 got FullCalendar working with the Google Calendar v3 API. This issue has been present since at least v2 API.

E Johnson’s picture

Any ideas? Really don't want to abandon the Google Calendar feed since it's so quick to add events and the website has multiple events per day.

Starting to see a lot of confusion from users this year using mobile devices.

Is there a way to prevent the Google Calendar link for each event from being shown (ie. so it's just text and no hyperlink)? Perhaps, I can just make the Time show up when you click it on a mobile device using jQuery.

Or is there a way to alter the Google Calendar link to include and set the default timezone to EST Toronto?

E Johnson’s picture

Well, after thinking the problem lies on Google's Calendar End and the way Google tries to interpret where the User is located automatically or based off their account settings. I'm not so sure the problem isn't on FullCalendar's end now.

After delving into the View's FullCalendar: Google Calendar "Time zone" setting (see screenshot), this appears not to be working properly or messing up the Event's link to a Google Calendar Event.

As a band-aid solution, I hard-coded the Timezone into the fullcalendar.fullcalendar.js file located in the "js" folder. I'm hoping this solves my issue everywhere where a visitor is seeing the incorrect time.

On Lines 17 and 20 I added the Timezone:

if (settings.sameWindow) {
   window.open(calEvent.url+'&ctz=America/Toronto', '_self');
}
else {
   window.open(calEvent.url+'&ctz=America/Toronto');
}

I found this solution from: http://stackoverflow.com/questions/10763734/how-to-build-html-link-to-a-...

As far as I can tell, the Event link that is generated by FullCalendar is incorrect for Anonymous users of the website or when they're not logged into a Google account with a Timezone set.

Not sure if this is working as desired. The GMT Timezone that was showing for my events makes absolutely no sense to me. Everywhere I read on the Google Calendar Product Forum, the default is UTC unless you set the default timezone for a Calendar (or Event).

Just adding this information in case it helps someone in the future.