So, in dealing with the Google Data API most dates use the format above. Here is a regular expression to decompose it:
Now remember that the constructor for the Date object is quite a pain. It considers Januaray to be month 0, and the first day of the month to be the zero’th day of the month.. With this in mind, you can construct the Date object.
Now, switch to the time-zone of the user..
That’s it folks!
Thanks, looking for some time for this
How are you doing?
It’s Mathieu C. from New World!
Nice stuff you did for the GData!
By the way there a small error in your date parsing it should be:
var time:Date = new Date(res, res – 1, res , res, res, res, res);
day are from 1-31
Do you any GData API that can post to youtube (comments, ratings)?
if you download the youtube data api from source (subversion), you’ll notice there is code to post also. Not all the functionality is implemented however. You can even upload videos to youtube using the API, but because the response (304 if I remember well) doesn’t work on Safari for Mac I didn’t post anything about it. It works like a charm on all other browsers that I tested however.
Look for YoutubeData in there, it should help. 😉