Update caused Fatal error: Can't use function return value in write context in /

Home Forums Calendar Products Events Calendar PRO Update caused Fatal error: Can't use function return value in write context in /

Viewing 10 posts - 1 through 10 (of 10 total)
  • Author
    Posts
  • #1180217
    Jon Coward
    Participant

    I also get a backend error after the Oct. 3oth update.

    Fatal error: Can’t use function return value in write context in /home/yfc2014site/public_html/dynastyfordcheer.com/wp-content/plugins/events-calendar-prox/src/functions/template-tags/venue.php on line 97

    #1180234
    AMPERAGE
    Participant

    I had the same exact problem! I have plugins set to auto-update so this was an unwelcome surprise!

    Change line 97 of events-calendar-pro/src/functions/template-tags/venue.php from:
    return ! empty( tribe_get_events( $args ) );
    to:

    
    $tribe_events = tribe_get_events( $args );
    return ! empty( $tribe_events );
    

    This should fix the problem as I didn’t get a fatal error after that.

    #1180244
    laughmasters
    Participant

    Thanks @amperage.
    Works for me too.
    -LMA

    #1180246
    pearvermont
    Participant

    Brilliant! Thank you very much for this fix.

    Cheers,
    PEAR Vermont

    #1180270
    George
    Participant

    Hey there,

    We ran into an issue with the packaging of the 4.3.1 update of The Events Calendar and Event Tickets.

    There are two main solutions to proceed and work around these issues.

    First: Replace the Files of The Events Calendar 4.3.1.1

    • If you are able to access your site files via FTP, head to the /wp-content/plugins directory and delete the /the-events-calendar folder there. This will not delete event content.
    • Once that is deleted, download a fresh copy of The Events Calendar 4.3.1.1 from WordPress.org ? http://wordpress.org/plugins/the-events-calendar
    • Install this new fresh copy of The Events Calendar 4.3.1.1 on your site.

    ⚠️ Please Note: If you have Event Tickets on your site, you may also want to do this process for Event Tickets 4.3.1.1, available on WordPress.org here.

    Next: PHP 5.2 Fix

    If you do the above steps and still see fatal error when you try to access your site, then this is the result of your site’s server running an old version of PHP.

    To proceed, first please contact your web host and ask them to upgrade the version of PHP they are running. While we do try to support old versions of PHP 5.2, because WordPress itself does, using out-of-date versions of software like this is bad for security and site performance.

    You can contact your web host and request they update their servers by sending a message like this:


    I'm interested in running the open-source WordPress (https://wordpress.org/) web software and I was wondering if my account supported the following:

    • PHP 5.6 or greater
    • MySQL 5.6 or greater
    • The mod_rewrite Apache module

    Thanks!

    Then, you have two options for a temporary fix:

    • You can head to line 97 of events-calendar-pro/src/functions/template-tags/venue.php from this:

      return ! empty( tribe_get_events( $args ) );

      to this:

      $tribe_events = tribe_get_events( $args );
      return ! empty( $tribe_events );

    • Or you can delete The Events Calendar 4.3.1.1 and Events Calendar Pro 4.3.1 from your site and temporarily re-install versions 4.3 of both plugins until we release a fix for this issue—which we will do promptly and are working on as I type this response.

    Thank you so much for your patience! Please let us know if you have further questions on this matter or anything else we can try to help with.

    Sincerely,
    George

    #1180384
    Natalia Neira
    Participant

    Thanks. FWIW, I had the same problem on a site running PHP 5.4. Had to update to 5.6.

    Bob

    #1180535
    Jon Coward
    Participant

    The temporary fix works. Hopefully there will be an official full patch soon

    #1181106
    George
    Participant

    Thanks for your patience and updates here, Bob and Jon.

    At this time, we have published official patches for the problems. You should be able to proceed by updating The Events Calendar to version 4.3.1.1 and Events Calendar Pro to 4.3.1.1, as well.

    Note that the version numbers here are NOT 4.3.1, but 4.3.1.1 :slightly_smiling_face:!

    I hope these new versions help—you can download fresh files any time at http://theeventscalendar.com/my-account/downloads

    Cheers, and sorry for the trouble here!

    George

    #1181422
    Natalia Neira
    Participant

    Thanks. I realize you were really just doing the WordPress community a service by encouraging us to update our PHP versions. 🙂

    Bob

    #1181628
    George
    Participant

    Sorry for the trouble with these problems, Bob! If some folks did end up upgrading PHP because of these problems, that’s certainly a boon for the security of their sites and—in many cases—the performance of their sites, too.

    Cheers,
    George

Viewing 10 posts - 1 through 10 (of 10 total)
  • The topic ‘Update caused Fatal error: Can't use function return value in write context in /’ is closed to new replies.