Title: PHP7 Compatibility
Last modified: January 17, 2017

---

# PHP7 Compatibility

 *  Resolved [Justin Korn](https://wordpress.org/support/users/themonko/)
 * (@themonko)
 * [9 years, 4 months ago](https://wordpress.org/support/topic/php7-compatibility-70/)
 * We’re doing some PHP7 Compatibility testing and this plugin was flagged. Just
   curious if this is legacy/fallback code or something we need to be concerned 
   about as we move to PHP7.
 * Thanks!
 * FILE: /app/public/wp-content/plugins/wp-typography/php-typography/class-php-typography.
   php
    ————————————————————————————————— FOUND 27 ERRORS AFFECTING 27 LINES —————————————————————————————————
   2131 | ERROR | preg_replace() – /e modifier is deprecated since PHP 5.5 and removed
   since PHP 7.0 2152 | ERROR | preg_replace() – /e modifier is deprecated since
   PHP 5.5 and removed since PHP 7.0 2323 | ERROR | preg_replace() – /e modifier
   is deprecated since PHP 5.5 and removed since PHP 7.0 2324 | ERROR | preg_replace()–/
   e modifier is deprecated since PHP 5.5 and removed since PHP 7.0 2325 | ERROR
   | preg_replace() – /e modifier is deprecated since PHP 5.5 and removed since 
   PHP 7.0 2326 | ERROR | preg_replace() – /e modifier is deprecated since PHP 5.5
   and removed since PHP 7.0 2327 | ERROR | preg_replace() – /e modifier is deprecated
   since PHP 5.5 and removed since PHP 7.0 2328 | ERROR | preg_replace() – /e modifier
   is deprecated since PHP 5.5 and removed since PHP 7.0 2329 | ERROR | preg_replace()–/
   e modifier is deprecated since PHP 5.5 and removed since PHP 7.0 2330 | ERROR
   | preg_replace() – /e modifier is deprecated since PHP 5.5 and removed since 
   PHP 7.0 2339 | ERROR | preg_replace() – /e modifier is deprecated since PHP 5.5
   and removed since PHP 7.0 2348 | ERROR | preg_replace() – /e modifier is deprecated
   since PHP 5.5 and removed since PHP 7.0 2349 | ERROR | preg_replace() – /e modifier
   is deprecated since PHP 5.5 and removed since PHP 7.0 2350 | ERROR | preg_replace()–/
   e modifier is deprecated since PHP 5.5 and removed since PHP 7.0 2351 | ERROR
   | preg_replace() – /e modifier is deprecated since PHP 5.5 and removed since 
   PHP 7.0 2352 | ERROR | preg_replace() – /e modifier is deprecated since PHP 5.5
   and removed since PHP 7.0 2353 | ERROR | preg_replace() – /e modifier is deprecated
   since PHP 5.5 and removed since PHP 7.0 2354 | ERROR | preg_replace() – /e modifier
   is deprecated since PHP 5.5 and removed since PHP 7.0 2355 | ERROR | preg_replace()–/
   e modifier is deprecated since PHP 5.5 and removed since PHP 7.0 2453 | ERROR
   | preg_replace() – /e modifier is deprecated since PHP 5.5 and removed since 
   PHP 7.0 2547 | ERROR | preg_replace() – /e modifier is deprecated since PHP 5.5
   and removed since PHP 7.0 2548 | ERROR | preg_replace() – /e modifier is deprecated
   since PHP 5.5 and removed since PHP 7.0 2553 | ERROR | preg_replace() – /e modifier
   is deprecated since PHP 5.5 and removed since PHP 7.0 2636 | ERROR | preg_replace()–/
   e modifier is deprecated since PHP 5.5 and removed since PHP 7.0 2639 | ERROR
   | preg_replace() – /e modifier is deprecated since PHP 5.5 and removed since 
   PHP 7.0 2642 | ERROR | preg_replace() – /e modifier is deprecated since PHP 5.5
   and removed since PHP 7.0 2646 | ERROR | preg_replace() – /e modifier is deprecated
   since PHP 5.5 and removed since PHP 7.0 —————————————————————————————————

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

 *  Plugin Author [pepe](https://wordpress.org/support/users/pputzer/)
 * (@pputzer)
 * [9 years, 4 months ago](https://wordpress.org/support/topic/php7-compatibility-70/#post-8686423)
 * Sorry for the laggy response time, [@themonko](https://wordpress.org/support/users/themonko/),
   somehow I didn’t get the notification for this topic.
 * No need to worry, wp-Typography has never used the `/e` modifier and is 100 percent
   compatible with PHP 7.x – in fact, I’m using and developing on and for that platform,
   so if anything, sometimes a 5.3 problem creeps in 😉
 * Since this got [recently reported on GitHub](https://github.com/mundschenk-at/wp-typography/issues/90)
   as well: What version of PHP and what compatibility plugin where you testing 
   this on (I assume it’s a current version of wp-Typography)? I’ve tried to reproduce
   the result to see where the false positive comes from, but have been unable to
   do so on my machines.
    -  This reply was modified 9 years, 4 months ago by [pepe](https://wordpress.org/support/users/pputzer/).
 *  Thread Starter [Justin Korn](https://wordpress.org/support/users/themonko/)
 * (@themonko)
 * [9 years, 4 months ago](https://wordpress.org/support/topic/php7-compatibility-70/#post-8689720)
 * No worries, [@pepe](https://wordpress.org/support/users/pepe/), thanks for the
   response.
 * Yes, latest version of the wp-Typography plugin and we’re using WP Engine’s checker:
   [https://wordpress.org/plugins/php-compatibility-checker/](https://wordpress.org/plugins/php-compatibility-checker/)
 * In case it wasn’t obvious, the log I posted shows you the file and line in which
   the error is being reported. All errors are in the /wp-typography/php-typography/
   class-php-typography.php file and the first column is the line, i.e. 2131, 2152
   etc.
 * Thanks again!
 *  Plugin Author [pepe](https://wordpress.org/support/users/pputzer/)
 * (@pputzer)
 * [9 years, 4 months ago](https://wordpress.org/support/topic/php7-compatibility-70/#post-8689758)
 * The strange thing is, the last line in version 4.0.1 of `class-php-typography.
   php` is [2182](https://github.com/mundschenk-at/wp-typography/blob/4.0.x/php-typography/class-php-typography.php#L2182)
   and the supposed error lines lie between [2131](https://github.com/mundschenk-at/wp-typography/blob/4.0.x/php-typography/class-php-typography.php#L2131)
   and the non-existent 2646.
 *  Thread Starter [Justin Korn](https://wordpress.org/support/users/themonko/)
 * (@themonko)
 * [9 years, 4 months ago](https://wordpress.org/support/topic/php7-compatibility-70/#post-8689785)
 * Hmm…it is possible I ran the test before updating, copied the log, realized I
   wasn’t up-to-date and then ran again but still saw issues. Unfortunately, I can’t
   remember which of my client’s installs had this plugin to double check.
 * I’ll run through a few to see if I can find it and if I do, I’ll run the test
   again and double check the logs.
 * Thanks!
 *  Plugin Author [pepe](https://wordpress.org/support/users/pputzer/)
 * (@pputzer)
 * [9 years, 4 months ago](https://wordpress.org/support/topic/php7-compatibility-70/#post-8693021)
 * Look up the version of the PHP Compatibility Checker plugin if you can, please.
   I tried to reproduce the false positives with version 1.3.2 and could not.
 *  Thread Starter [Justin Korn](https://wordpress.org/support/users/themonko/)
 * (@themonko)
 * [9 years, 4 months ago](https://wordpress.org/support/topic/php7-compatibility-70/#post-8708830)
 * Yep, using 1.3.2.
 *  Plugin Author [pepe](https://wordpress.org/support/users/pputzer/)
 * (@pputzer)
 * [9 years, 4 months ago](https://wordpress.org/support/topic/php7-compatibility-70/#post-8709455)
 * Strange indeed. The only thing that comes to mind (although quite far-fetched)
   is some sort of caching issue, maybe with an opcode cache?
 * In any casw, it’s a false positive, so no need to worry. Upgrading to PHP 7.x
   is highly recommended!

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

The topic ‘PHP7 Compatibility’ is closed to new replies.

 * ![](https://ps.w.org/wp-typography/assets/icon.svg?rev=2663995)
 * [wp-Typography](https://wordpress.org/plugins/wp-typography/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/wp-typography/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/wp-typography/)
 * [Active Topics](https://wordpress.org/support/plugin/wp-typography/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/wp-typography/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/wp-typography/reviews/)

 * 7 replies
 * 2 participants
 * Last reply from: [pepe](https://wordpress.org/support/users/pputzer/)
 * Last activity: [9 years, 4 months ago](https://wordpress.org/support/topic/php7-compatibility-70/#post-8709455)
 * Status: resolved