Support

Home Forums Event Espresso Premium Timezones changing problem

Timezones changing problem

Posted: December 1, 2015 at 9:50 pm


Kevin Bull

December 1, 2015 at 9:50 pm

I made a simple mistake by leaving my website on standard time, and simply overlooked the issue that ticket sales would be starting and ending at the wrong time.

But now I want to fix the problem. I tried simply updating my site to the timezone I wanted to use, thinking that this would let event espresso know what I wanted. BUT for some reason the events CHANGE the dates and times I put in and adjust them to compensate for the time change on the website, making it apparently impossible change the dates and times without going through every ticket I have created across a dozen events and manually change them one at a time.

Is there some more reasonable way to do this that I have missed? And as a follow up I am planning to have events in different timezones soon is that simply not supported in event espresso?


Tony

  • Support Staff

December 2, 2015 at 1:12 am

Hi Kevin,

Do you have any other plugins that deal with dates or time?

This can be a calendar plugin, a post expiration plugin etc

What I suspect is happening is another plugin is using date_default_timezone_set() which causes problems within WordPress as it expects the timezone on the server to always be UTC and works from there.

And as a follow up I am planning to have events in different timezones soon is that simply not supported in event espresso?

Not currently.


Kevin Bull

December 2, 2015 at 3:30 am

I do not have any calendar plugins or anything that deals with date and time directly.

I also don’t see how date_default_timezone_set() would cause the dates to auto adjust within event espresso to brand new times when the server time is changed. Are the dates stored based on a UTC timestamp rather than a string?


Tony

  • Support Staff

December 2, 2015 at 7:43 am

Ah, sorry I misunderstood.

date_default_timezone_set() causes the same problem in that it alters the given by the server and then the offsite is applied to that time (which means its effectively added twice) this becomes apparent on saving the events.

Are the dates stored based on a UTC timestamp rather than a string?

All of our dates are based on UTC+0 mysql timestamp and are stored using the mysql timestamp format: Y-m-d H:i:s

The offset from the currently selected timezone is applied to the date when displayed, which is why changing the timezone within WP changes the date that is output.

To fix this you’ll need to edit each event, confirm the dates/times are correct and re-save the event.

The support post ‘Timezones changing problem’ is closed to new replies.

Have a question about this support post? Create a new support post in our support forums and include a link to this existing support post so we can help you.

Event Espresso