Support » Plugin: W3 Total Cache » Fatal error upon comment post

  • Hi, I’m currently running a social website where users need to leave comments, but upon doing so they get the following error

    Fatal error: Class ‘W3TC\stdClass’ not found in /home/jerseype/public_html/wp-content/plugins/w3-total-cache/Util_PageUrls.php on line 527

Viewing 4 replies - 1 through 4 (of 4 total)
  • The fix is:

    Open this file: /wp-content/plugins/w3-total-cache/Util_PageUrls.php

    Change line 527 from:
    $GLOBALS[‘post’] = new stdClass();

    To this:
    $GLOBALS[‘post’] = new \stdClass();

    It has to deal with a namespacing issue. I hope the plugin developers see this.


    ^ Also make sure to be running a php version greater than 5.2 to avoid other errors \0

    thx tselaty jr, that resolve the issue that begun with 0.9.5

    Had the exact same error with PHP 5.6 right now. Posting comments was not possible. The above code fixed it – working fine again. Wondering why this fix isn’t in the latest update yet…

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Fatal error upon comment post’ is closed to new replies.