Viewing 8 replies - 1 through 8 (of 8 total)
  • Just want to note that I am having the exact same problem as well.

    Thread Starter AndreaGabriel

    (@andreagabriel)

    Hi there.

    So I tested the same code on two identical installations of the site, with different results on each. As the WP and plugins are the same on each, I have to believe it is something to do with the server. I’ll check back in.

    Yes, I think it’s pulling the server’s default time instead of the default timezone set within WordPress. But that’s just a guess at this point. Any help in this area would be greatly appreciated. Thank you!

    Thread Starter AndreaGabriel

    (@andreagabriel)

    Hmmm. Well, I take back what I wrote above, as there were two different options checked inside Events Calendar settings (use local time on events or use sitewide time on events.) That accounts for the differences I was seeing, but did not change the fact that they both dropped all of today’s events at 5 pm PST, which happens to be Coordinated Universal Time, so am suspicious that the plugin is not accounting for local time differences.

    I have Events Calendar Pro, so was able to test their widget shortcode, and it is working just fine in this regard, so it is something going on with this plugin.

    Thread Starter AndreaGabriel

    (@andreagabriel)

    Any help here would be fantastic. I love this plugin because of its versatility, but it is not functional for me if events disappear off the site at UTC midnight instead of when the event is over.

    This page shows the issue (or will until tomorrow morning.)

    https://www.earshot.org/slide-test-page/

    The top section represents the following code:

    [ecs-list-events limit=’5′]

    The bottom represents the MT code:

    [tribe_events_list limit=”5″]

    The two codes are pulling different information, obviously. I will keep looking for a solution on my end, but would love any insight others can offer.

    Thread Starter AndreaGabriel

    (@andreagabriel)

    The problem will no longer be obvious once all of tonights events are over and disappear off the section driven by the Modern Tribe shortcode. So here is a link to a screenshot as it appears right now:

    https://www.earshot.org/wp-content/uploads/2015/09/Screen-Shot-2015-09-21-at-6.45.21-PM.png

    OK I believe I have a temporary fix until the developer releases an update.

    In the-events-calendar-shortcode.php, find line 115. It should look like this:

    $meta_date_date = date( 'Y-m-d' );

    Update that line to look like this:

    date_default_timezone_set('America/Los_Angeles');
    $meta_date_date = date( 'Y-m-d H:i:s' );

    Obviously, you’ll need to update the setting of the timezone to your appropriate location. See https://php.net/manual/en/timezones.php

    That is working for me right now. My web server’s default time zone is set to UTC, but my WP installation is set to America/Los_Angeles.

    I’m running WordPress 4.3.1

    Thread Starter AndreaGabriel

    (@andreagabriel)

    Thanks! I am in your same time zone, so easy for me to just cut and paste. I will know by 5 tonight how it is working.

Viewing 8 replies - 1 through 8 (of 8 total)
  • The topic ‘Events Cutting off at UTC midnight instead of local time midnight’ is closed to new replies.