Title: PHP7 compatibility
Last modified: May 3, 2018

---

# PHP7 compatibility

 *  Resolved [laraej](https://wordpress.org/support/users/laraej/)
 * (@laraej)
 * [7 years, 11 months ago](https://wordpress.org/support/topic/php7-compatibility-97/)
 * It seems that Compress JPEG & PNG images plugin is not fully compatible with 
   PHP 7. Based on a PHP compatibility test I noticed the following warning:
 * FILE: /better-search-replace-pro/includes/class-bsr-compatibility.php
    —————————————————————————————–
   INI directive ‘safe_mode’ is deprecated since PHP 5.3 and removed since PHP 5.4—————————————————————————————–

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

 *  Plugin Author [TinyPNG](https://wordpress.org/support/users/tinypng/)
 * (@tinypng)
 * [7 years, 11 months ago](https://wordpress.org/support/topic/php7-compatibility-97/#post-10243919)
 * Hi, could it be you pasted your question in the wrong place? The plugin is fully
   PHP7 compatible and the file you talk about is not part of the plugin. Maybe 
   this refers to the plugin “Better Search Replace Pro”.
 *  Thread Starter [laraej](https://wordpress.org/support/users/laraej/)
 * (@laraej)
 * [7 years, 11 months ago](https://wordpress.org/support/topic/php7-compatibility-97/#post-10244218)
 * Hi, sorry I had copied the wrong warning message. But I am actually referring
   to your plugin, Compress JPEG & PNG images as below:
 * FILE: /wp-content/plugins/tiny-compress-images/src/class-tiny-notices.php
    —————————————————————————————–
   134 | WARNING | Function create_function() is deprecated since PHP 7.2; Use an
   anonymous function instead —————————————————————————————–
 * Just wondering if you know about this warning and if something needs to be done
   about it.
    Thanks in advance.
 *  Plugin Author [TinyPNG](https://wordpress.org/support/users/tinypng/)
 * (@tinypng)
 * [7 years, 11 months ago](https://wordpress.org/support/topic/php7-compatibility-97/#post-10244938)
 * Ok thanks. It is a deprecation warning so that sounds like something we will 
   definitely address in one of the next updates!
 *  Thread Starter [laraej](https://wordpress.org/support/users/laraej/)
 * (@laraej)
 * [7 years, 11 months ago](https://wordpress.org/support/topic/php7-compatibility-97/#post-10244961)
 * That would be good, thanks!
 *  [tobiasmalikowski](https://wordpress.org/support/users/tobiasmalikowski/)
 * (@tobiasmalikowski)
 * [7 years, 8 months ago](https://wordpress.org/support/topic/php7-compatibility-97/#post-10547291)
 * Hi there just updated to version 3.0 of your plugin.
    Unfortunately the warning
   still occurs on two instances.
 * tiny-compress-images/src/class-tiny-notices.php
 *  134 | WARNING | Function create_function() is deprecated since PHP 7.2; Use 
   an anonymous function instead
 *  169 | WARNING | Function create_function() is deprecated since PHP 7.2; Use 
   an anonymous function instead
 * Can you please integrate a fix for this in the next version. Fix is pretty easy
   see [PHP Manual](http://php.net/manual/en/functions.anonymous.php).
 * Thank you, have a nice day.
 * Tobias
    -  This reply was modified 7 years, 8 months ago by [tobiasmalikowski](https://wordpress.org/support/users/tobiasmalikowski/).
 *  Plugin Author [TinyPNG](https://wordpress.org/support/users/tinypng/)
 * (@tinypng)
 * [7 years, 8 months ago](https://wordpress.org/support/topic/php7-compatibility-97/#post-10563123)
 * Hi Tobias,
 * Thanks for bringing this to our attention again. We indeed forgot to address 
   it in 3.0.0, but since we also introduced a bug in 3.0.0 that we wanted to quickly
   fix, we’ve just released 3.0.1 in which you no longer should get these warnings
   as we no longer use create_function().

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

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

 * ![](https://ps.w.org/tiny-compress-images/assets/icon-256x256.png?rev=3448487)
 * [TinyPNG - JPEG, PNG & WebP image compression](https://wordpress.org/plugins/tiny-compress-images/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/tiny-compress-images/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/tiny-compress-images/)
 * [Active Topics](https://wordpress.org/support/plugin/tiny-compress-images/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/tiny-compress-images/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/tiny-compress-images/reviews/)

## Tags

 * [php](https://wordpress.org/support/topic-tag/php/)

 * 6 replies
 * 3 participants
 * Last reply from: [TinyPNG](https://wordpress.org/support/users/tinypng/)
 * Last activity: [7 years, 8 months ago](https://wordpress.org/support/topic/php7-compatibility-97/#post-10563123)
 * Status: resolved