By JDev on Friday, 25 March 2016
Posted in Technical Issues
Replies 7
Likes 0
Views 768
Votes 0
What format is events start/end time stored in the DB + objects on system load? I'm using event->getEventStart() and end functions but they give me something that's 10 or more hours off of Central time which is what my Joomla install is set to....

Does it store/deal with time in UTC and convert on the fly based on server/joomla settings? If so, what and where is the code you handle for displaying start+end times properly on the front end. Thanks.

Update:
I took a closer look and it appears all your date times are set in GMT, and our timezone is ignored completely in joomla settings and etc. So even if I set something to 5PM, you just set 5PM GMT, which is wrong.....so when we look at the code it should be a different time in GMT if we're saying 5PM central. So that's why our display is all messed up. This causes us issues since we deal with people all over the globe, is there no timezone to deal with specificially so users can up convert/set their timezone accordingly?

So I assume it was just easier to do no timezone stuff....but I don't think this is right. We definately need to show that an event is for CST or some time zone, and it would be even better if a user could pick timezone in their profile and adjust display across easysocial, but that's not as important as at least highlighting the fact a time is in CST, except you guys just set everything to GMT :S
The correct datetime stored should be GMT which is what we are storing right now. If your event is hosted in another country, then you can set the timezone when creating / editing the event.

All it does is display the timezone beside the date and time. We do not compute the date time strings as this would be too confusing especially when your site have users from various countries.
·
Sunday, 27 March 2016 21:15
·
0 Likes
·
0 Votes
·
0 Comments
·
Thank you for this information Mark.

In the database, start date is:
2016-03-25 20:00:00

and in reminder email, start time was 21:00. So it seems date time was computed...
·
Sunday, 27 March 2016 22:35
·
0 Likes
·
0 Votes
·
0 Comments
·
Hi Altitudes,

Yes that's correct. The final output time will be determined by the GMT set by your joomla and the user that created the event hence the value will not be the same as from database value.
·
Monday, 28 March 2016 15:46
·
0 Likes
·
0 Votes
·
0 Comments
·
I see no where to set timezone for events, nor do I see anywhere to set it to display timezone on the front end of the site for easysocial.

Storing an event time of 5:00PM (joomla, server, and mysql are all in CST/CDT) so when I look in the database 5:00pm CST != 5:00pm GMT, and 5:00pm is stored in the database so this is wrong.

Please kindly inform me how to set timezone for events and how to change format on front end so it displays timezone and this will probably be good enough.
·
Monday, 28 March 2016 20:55
·
0 Likes
·
0 Votes
·
0 Comments
·
There should not be any "calculation" of timezone on the date / time when being stored or displayed. The date / time stored is as is. When you edit or create an event, you can select a timezone and the timezone will be displayed beside the date, http://screencast.com/t/oTIxhSQKSsf
·
Tuesday, 29 March 2016 00:09
·
0 Likes
·
0 Votes
·
0 Comments
·
Found it, had to edit the field and show timezone.

Is there a way to default it to our timezone and not have it be UTC by default? Also, how do I change the format so it's not America/Winnipeg on the front end but uses CST/CDT notation available in php's date time format?
·
Tuesday, 29 March 2016 22:47
·
0 Likes
·
0 Votes
·
0 Comments
·
Hey there,

I am sorry for the delay of this reply,

Is there a way to default it to our timezone and not have it be UTC by default?

It actually follow back what you configure that server timezone from your backend global configuration setting, if you set UTC by default from your Joomla backend server timezone, then it will see your current logged in user profile timezone settings.

Also, how do I change the format so it's not America/Winnipeg on the front end but uses CST/CDT notation available in php's date time format?

I am a little bit lost here, do you mean you would like to display CST/CDT instead of America/Winnipeg from the timezone selection? Please advise.
·
Wednesday, 30 March 2016 16:55
·
0 Likes
·
0 Votes
·
0 Comments
·
View Full Post