Title: PHP 7 Compatibility Errors
Last modified: December 25, 2016

---

# PHP 7 Compatibility Errors

 *  Resolved [Ken](https://wordpress.org/support/users/kronomia/)
 * (@kronomia)
 * [9 years, 5 months ago](https://wordpress.org/support/topic/php-7-compatibility-errors-2/)
 * **File: wp-piwik/classes/WP_Piwik.php**
    Line: 353 | Using ‘break’ outside of
   a loop or switch structure is invalid and will throw a fatal error since PHP 
   7.0
 * **File: wp-piwik/proxy/piwik.php**
    Line: 98 | INI directive ‘magic_quotes_runtime’
   is deprecated since PHP 5.3 and removed since PHP 5.4.
 * Thanks in advance for reading my notes!

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

 *  Plugin Author [braekling](https://wordpress.org/support/users/braekling/)
 * (@braekling)
 * [9 years, 5 months ago](https://wordpress.org/support/topic/php-7-compatibility-errors-2/#post-8589205)
 * [https://wordpress.org/support/topic/php7-compatible-15/](https://wordpress.org/support/topic/php7-compatible-15/)
   
   [https://wordpress.org/support/topic/php-7-compatibility-88/](https://wordpress.org/support/topic/php-7-compatibility-88/)
   [https://wordpress.org/support/topic/php7-compatibility-31/](https://wordpress.org/support/topic/php7-compatibility-31/)
 * > Requirements: PHP 5.4 (or higher)/PHP 7.0 (or higher), WordPress 4.0 (or higher),
   > Piwik 2.16 (or higher)
 * = WP-Piwik is PHP 7 compatible.
 *  [GermanKiwi](https://wordpress.org/support/users/germankiwi/)
 * (@germankiwi)
 * [9 years, 3 months ago](https://wordpress.org/support/topic/php-7-compatibility-errors-2/#post-8732479)
 * Hi [@braekling](https://wordpress.org/support/users/braekling/),
 * I know you’ve already commented on PHP7 compatibility at [https://wordpress.org/support/topic/php7-compatibility-31](https://wordpress.org/support/topic/php7-compatibility-31)
   and I trust you that your plugin is compatible. However, in the detailed answer
   you gave at that other post, you only explained the issue about “magic_quotes_runtime”.
 * There’s another “error” given by the the PHP Compatibility Checker plugin, which
   is:
 * File: wp-piwik/classes/WP_Piwik.php
    Line: 353 | Using ‘break’ outside of a loop
   or switch structure is invalid and will throw a fatal error since PHP 7.0
 * Would you be so kind as to explain why this is also not a problem with PHP7? 
   I’m not an expert on this so it would be nice to understand why I can ignore 
   it! Thanks!
 *  Plugin Author [braekling](https://wordpress.org/support/users/braekling/)
 * (@braekling)
 * [9 years, 3 months ago](https://wordpress.org/support/topic/php-7-compatibility-errors-2/#post-8733179)
 * Well, this is no problem because the error does not exist, the break is not outside
   a loop – the validator is wrong.
 *     ```
       foreach ($userRoles as $userRole)
       	if (isset( $allowed[$userRole] ) && $allowed[$userRole]) {
       		$cap = 'read';
       		break;
       }
       ```
   
 *  [Bub](https://wordpress.org/support/users/jdenning47/)
 * (@jdenning47)
 * [9 years, 2 months ago](https://wordpress.org/support/topic/php-7-compatibility-errors-2/#post-8863475)
 * And I can’t use this with WP-Engine due to the [Compatablity Plugin](https://wordpress.org/plugins/php-compatibility-checker/?utm_medium=email&utm_source=hubspot&utm_campaign=php7&_hsenc=p2ANqtz--EYo5-5yHaPupSJF7YRfCKO2HicCBBrm7oUTnQ0DrhNEwyIGM40YvdTLSXeuZFD3uL15k-Xp1WnLQScFRfEarOhrLAD6dhXbMcqnkIfnKxY8xHOSk&_hsmi=43149489)
   error.

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

The topic ‘PHP 7 Compatibility Errors’ is closed to new replies.

 * ![](https://ps.w.org/wp-piwik/assets/icon-256x256.png?rev=3529668)
 * [Connect Matomo - Analytics Dashboard for WordPress](https://wordpress.org/plugins/wp-piwik/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/wp-piwik/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/wp-piwik/)
 * [Active Topics](https://wordpress.org/support/plugin/wp-piwik/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/wp-piwik/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/wp-piwik/reviews/)

## Tags

 * [PHP7](https://wordpress.org/support/topic-tag/php7/)
 * [piwik](https://wordpress.org/support/topic-tag/piwik/)

 * 4 replies
 * 4 participants
 * Last reply from: [Bub](https://wordpress.org/support/users/jdenning47/)
 * Last activity: [9 years, 2 months ago](https://wordpress.org/support/topic/php-7-compatibility-errors-2/#post-8863475)
 * Status: resolved