Google Calendar generates incorrect time in xml feed - ruby-on-rails

I'm generating an ICS feed from an exchange server with the timezone set to "UTC Dublin, Edinburgh, Lisbon, London"; I'm then importing this into Google Calendar, which then creates an XML feed which I then import into FullCalendar in my Rails application.
The ICS feed from the exchange server has this:
SUMMARY:Test Event
DTSTART;TZID=GMT Standard Time:20140713T000000
DTEND;TZID=GMT Standard Time:20140719T000000
However the XML feed generated by Google Calendar, is wrong. it shows:
<title type='html'>Y12 Biology Field Trip</title><summary type='html'>When: Sat 12 Jul 2014 23:00 to Fri 18 Jul 2014 23:00&nbsp;
UTC<br>
How do I correct the xml feed created by Google Calendar? It appears it isn't using GMT Daylight saving.
Or, how do I force use of Daylight saving in Google Calendar/FullCalendar?

My 2nd go at this... For me, there is nothing incorrect in the google feed. Google is receiving a time in "GMT Standard Time", an ambiguous time zone which, contrary to what you might expect, may have daylight saving. It then converts this time to UTC (no daylight saving), It does this because UTC is the timezone of the google calendar. Events imported into a google calendar are converted to the time zone of the google calendar. So midnight becomes 11pm.
I don't know fullcalendar, but the google xml feed is not suited for digestion by machines. Event times are mixed up in text descriptions. The timezone information is too short to be definitive. You would be much better sticking with Icalendar for exchanging calendar information. Why can't full calendar handle the Ical feed directly from Exchange? If you persist with google xml, try changing the time zone setting on the google calendar.

Related

Is there a way to have a different timezone saved for one website only in Chrome?

I live in the Eastern timezone, but need to see a site in local time (Central time). Is there a way to permanently set the timezone for a specific website in Chrome?
Thx

Twitter API: How can I know the exactly hour a tweet was created?

I'm dealing with the Twitter API.
I need to know the hour exactly when the tweet was created. Meaning, the real locate hour where that guy was stand.
For example: If I create a tweet at 5PM Argentina Hour, I want to get "5PM" in the Twitter api.
The problem, is that the Twitter API always return the UTC hour, meaning, it's always "+0000".
If I you don't know that I was in Argentina (-0300) in the moment I created the Tweet, you can't know that I tweeted at 5PM.
Absolutely all tweets are like this: Sun May 14 02:43:02 +0000 2017.
All of those numbers always change (Day, Month, Day number, hour, minutes, seconds, year) BUT the +0000 never change.
For example, If my tweet (at 5PM) should be like: Sun May 14 17:00:00 -0300 2017 (because I'm in Argentina at 5PM: 17PM). But the API say: "Sun May 14 20:00:00 +0000 2017". (17 + 3).
I can't know where the tweet come from (because 99,9999% of the users has no GeoLocation enabled).
What can you say?
EDIT:
I'm thinking that if Twitter give me that "-0300", twitter will be letting me know that I'm in Argentina, so, that will be movement against my provacity (and my no-geolocation-activated), so, makes sense that Twitter doesn't give us that information. But, anyways, I want to know what you say.
The only way to know what the user's local time was when he created the tweet is to know where the user was when the tweet was created.
If the tweet does not have geolocation information, then you cannot easily know where the user was at that time without doing broader analysis.
About 2% of Tweets contain geolocation data (source), so that's a lot of tweets to work with.

Check if date is correct in IOS

Currently, I am grabbing the current date by NSDate().timeIntervalSince1970. However, I am concerned that the user will change the date on the phone to mess with my app. So I was wondering which of the two options below is a more suitable fix
Is there some sort of Apple way to grab the current date from an apple server.
Is there a good and reliable API where I can grab current date?
Use the TIMEAPI available at www.timeapi.org
You can retrieve the current time in UTC here.

YouTube Live Streaming API Broadcast Start Date Timezone Not Working

I'm using youtube live streaming api to setup my live events. When I set date to scheduledStartTime and save the event, it stores date time but it ignores Timezone.
No matter what timezone value I set, I always end up with (GMT-7). Here is an example of what I set 2015-09-10T21:00:00.0000000+04:00 I'd end up with (GMT+4)
Does anybody knows how to solve it?
According to the YouTube Live Streaming API Docs, the format for scheduledStartTime must be in ISO 8601 format:
datetime
The date and time that the broadcast is scheduled to start.
The value is specified in ISO 8601 (YYYY-MM-DDThh:mm:ss.sZ) format.
You didn't list a specific platform, but my working date format string on iOS is as follows:
YYYY-MM-dd'T'HH:mm:ssZZZZZ

grails datePicker submit date with timeZone

I am sending date through g:datePicker as Eastern time by default.
How do I have an option where i pass date based on the timeZone selected?
Please help.
Grails datepicker tag does not and should not deal with your timezone. Its just a presentation of date and accepts Date object. Meaning that whatever timezone the date object has it will be that.
There are number of libraries to handle timezone on client side such as ECMAScript Internationalization API, moment.js and many others. On the server side you have libraries such as Joda-time and so on. I am sure if you search on Google you can find plenty more options.
Just handle your timezone conversion, then the presentation layer could be Grails datepicker or bootstrap-datepicker or jquery and etc.

Resources