Strange Start date bug

Home Forums Calendar Products Events Calendar PRO Strange Start date bug

Viewing 8 posts - 1 through 8 (of 8 total)
  • Author
    Posts
  • #998005
    papertower
    Participant

    Greetings!

    I’m running into a pretty interesting bug wherein all new events have the wrong start date/time. It’s actually today’s date/time. This only occurs on the single page for the event; it displays correctly in the archive.

    I spent some time digging through your code, views, etc.. and what I eventually found was that the $GLOBAL[‘post’] event for the single has an invalid value. If I var_dump the contents of $event->EventStartDate the value is “{{UNKNOWN}}”. I tried tracing back to the point wherein the global $post is having that property set, but I can’t seem to find it. So apparently when the Date function is ultimately used to provide the formatted date, it doesn’t know what to do with that so it falls back on today’s date.

    I’m not modifying the views in the theme or anything like that. It’s a pretty pure setup.

    Thanks!

    • This topic was modified 10 years, 8 months ago by papertower.
    #998079
    George
    Participant

    Hey @papertower,

    Thanks for the report of this! This is definitely worth investigating. I’m a bit confused by your report here:

    If I var_dump the contents of $event->EventStartDate the value is “{{UNKNOWN}}”

    That hints at some other code possibly at fault with this bug, and I’d urge you to run through our complete set of troubleshooting steps outlined here → https://theeventscalendar.com/knowledgebase/testing-for-conflicts/

    Check on this weird bug behavior after each step in that process, and see if the behavior changes at all. This will be an extremely useful set of tests.

    Thank you!
    George

    #998779
    papertower
    Participant

    Hi George!

    If I var_dump the contents of $event->EventStartDate the value is “{{UNKNOWN}}”

    So what I’m doing here is taking the global $event object and using var_dump to view its contents. This is at the beginning of the single template. Within that object is the EventStartDate property, as well as the EventEndDate property. The EventEndDate has the value I’d expect, but for some reason the value of the EventStartDate property is a string value of “{{UNKNOWN}}”. Honestly, I’ve never seen that before.

    I’ll try debugging the theme/plugins and let you know what I find.

    #998784
    papertower
    Participant

    Greetings!

    I just changed to the Twenty-thirteen theme and disabled all the plugins except Events Calendar (and pro). I’m afraid the problem persists. Interestingly enough, when I look in the database, the start date meta is correct. Where does Events Calendar initially add the properties to the queried object?

    #999006
    George
    Participant

    Hey @papertower,

    Thanks for investigating this, and for your patience as we try and wrestle with this bug…this is very odd! I cannot recreate this at all.

    Can you share your system information with us? We have article on how to do so here for reference → https://theeventscalendar.com/knowledgebase/sharing-sys-info/

    Thank you!
    George

    #999638
    papertower
    Participant

    This reply is private.

    #999654
    George
    Participant

    Hey @papertower,

    Thank you for your patience and politeness with this stuff so far, it’s an odd issue and so unfortunately is moving a bit slower than I’m sure you’d find ideal!

    I did some digging and think that what might be happening here is a limitation on SQL joins by your host / on your server. To test this theory, on your local server try adding this code to your theme’s functions.php file:


    add_action( 'init', 'tribe_998005_allow_large_joins' );

    function tribe_998005_allow_large_joins(){
    global $wpdb;
    $wpdb->query('SET SQL_BIG_SELECTS=1');
    }

    1. Does that help at all on your local site?

    2. Before adding that code, I’d recommend reaching out to your web host support just to inquire about this and see if they have any input 🙂

    3. I see that you have WP Migrate DB Pro on your site – have you been importing data to and/or from your site with that plugin? The only other issues similar to this that I’ve been able to dig up have been related to issues after importing events from another Database, so that could be a key factor here if you are, indeed, transferring data between databases.

    4. Just to be 100% certain, if you create a brand new event for testing purposes, do you have these same issues? In other words, does this odd behavior only happen with pre-existing events, or does it happen even with brand-new events that you create? (this is somewhat related to my concerns in #3 here).

    Thanks so much @papertower – your information has been quite helpful and I feel like we’re getting closer to identifying exactly what is going on here.

    — George

    #1004198
    Support Droid
    Keymaster

    This topic has not been active for quite some time and will now be closed.

    If you still need assistance please simply open a new topic (linking to this one if necessary)
    and one of the team will be only too happy to help.

Viewing 8 posts - 1 through 8 (of 8 total)
  • The topic ‘Strange Start date bug’ is closed to new replies.