Title: Error if on PHP 7 server
Last modified: July 20, 2018

---

# Error if on PHP 7 server

 *  Resolved [spabav](https://wordpress.org/support/users/spabav/)
 * (@spabav)
 * [7 years, 10 months ago](https://wordpress.org/support/topic/error-if-on-php-7-server-2/)
 * Hi,
    we are running Version 1.16.7
 * When we set wp_debug to “true” in wp-config and run your plugin with php 7.2,
 * We get the following error message at the backend and frontend:
 * Deprecated: Function create_function() is deprecated in /mysite.com/wp-content/
   plugins/onesignal-free-web-push-notifications/onesignal-widget.php on line 46
 * Deprecated: The each() function is deprecated. This message will be suppressed
   on further calls in /mysite.com/wp-content/plugins/onesignal-free-web-push-notifications/
   onesignal-settings.php on line 122
 * Could you please let us know how we can fix this error?

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

 *  [Alain Aubry](https://wordpress.org/support/users/caban13/)
 * (@caban13)
 * [7 years, 9 months ago](https://wordpress.org/support/topic/error-if-on-php-7-server-2/#post-10594153)
 * I found the same, need to update for PHP 7.2.
    Thanks
 *  Plugin Author [OneSignal Push Notifications](https://wordpress.org/support/users/onesignal/)
 * (@onesignal)
 * [7 years, 9 months ago](https://wordpress.org/support/topic/error-if-on-php-7-server-2/#post-10594358)
 * We have clean up these warnings with our 1.16.8 release today!

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

The topic ‘Error if on PHP 7 server’ is closed to new replies.

 * ![](https://ps.w.org/onesignal-free-web-push-notifications/assets/icon.svg?rev
   =3003897)
 * [OneSignal - Web Push Notifications](https://wordpress.org/plugins/onesignal-free-web-push-notifications/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/onesignal-free-web-push-notifications/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/onesignal-free-web-push-notifications/)
 * [Active Topics](https://wordpress.org/support/plugin/onesignal-free-web-push-notifications/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/onesignal-free-web-push-notifications/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/onesignal-free-web-push-notifications/reviews/)

## Tags

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

 * 2 replies
 * 3 participants
 * Last reply from: [OneSignal Push Notifications](https://wordpress.org/support/users/onesignal/)
 * Last activity: [7 years, 9 months ago](https://wordpress.org/support/topic/error-if-on-php-7-server-2/#post-10594358)
 * Status: resolved