Title: W3TC Bug &amp; PHP 7 compatibility
Last modified: August 31, 2016

---

# W3TC Bug & PHP 7 compatibility

 *  [techsurgeons](https://wordpress.org/support/users/techsurgeons/)
 * (@techsurgeons)
 * [10 years, 4 months ago](https://wordpress.org/support/topic/w3tc-bug-php-7-compatibility/)
 * Frederick,
 * Thanks for W3TC!
 * With PHP 7 I’m seeing many errors like the one below:
    [error] [client X.X.X.
   X] FastCGI: server “/home/www/fastcgi.fcgi” stderr: PHP message: PHP Warning:
   Parameter 1 to W3_Plugin_TotalCache::ob_callback() expected to be a reference,
   value given in /home/www/site/wp-includes/functions.php on line 3553
 * Is there a reason to not make the below change to line 512 of lib/W3/Plugin/TotalCache.
   php?
    – function ob_callback(&$buffer) { + function ob_callback($buffer) {
 * It’s been suggested elsewhere, and seems to work wonderfully on 5.6 & 7.0x
 * Thanks!
 * [https://wordpress.org/plugins/w3-total-cache/](https://wordpress.org/plugins/w3-total-cache/)

Viewing 2 replies - 1 through 2 (of 2 total)

 *  [Haydrion Rayel](https://wordpress.org/support/users/haydrionrayel/)
 * (@haydrionrayel)
 * [10 years, 4 months ago](https://wordpress.org/support/topic/w3tc-bug-php-7-compatibility/#post-7316897)
 * saw this yesterday too …
 *  [Kimberly](https://wordpress.org/support/users/amiga500/)
 * (@amiga500)
 * [10 years, 4 months ago](https://wordpress.org/support/topic/w3tc-bug-php-7-compatibility/#post-7316933)
 * Correct..that IS what you need to do to make it function under 7.x…So you are
   good to go.

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘W3TC Bug & PHP 7 compatibility’ is closed to new replies.

 * ![](https://ps.w.org/w3-total-cache/assets/icon-256x256.png?rev=1041806)
 * [W3 Total Cache](https://wordpress.org/plugins/w3-total-cache/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/w3-total-cache/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/w3-total-cache/)
 * [Active Topics](https://wordpress.org/support/plugin/w3-total-cache/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/w3-total-cache/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/w3-total-cache/reviews/)

 * 2 replies
 * 3 participants
 * Last reply from: [Kimberly](https://wordpress.org/support/users/amiga500/)
 * Last activity: [10 years, 4 months ago](https://wordpress.org/support/topic/w3tc-bug-php-7-compatibility/#post-7316933)
 * Status: not resolved