Title: PHP Deprecated
Last modified: November 30, 2023

---

# PHP Deprecated

 *  Resolved [newshop](https://wordpress.org/support/users/newshop/)
 * (@newshop)
 * [2 years, 5 months ago](https://wordpress.org/support/topic/php-deprecated-40/)
 * Hello, I get the following notice in debug.log:
 *     ```wp-block-code
       [30-Nov-2023 11:43:07 UTC] PHP Deprecated:  str_contains(): Passing null to parameter #1 ($haystack) of type string is deprecated in [...]/wp-includes/shortcodes.php on line 246
       ```
   
 * I made several tests with enabling/disabling plugins and came to the result that
   this notice is caused by Back in Stock Notifier. I am using php version 8.1
 * Any help about how to fix that would be great.

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

 *  Thread Starter [newshop](https://wordpress.org/support/users/newshop/)
 * (@newshop)
 * [2 years, 5 months ago](https://wordpress.org/support/topic/php-deprecated-40/#post-17241942)
 * Also, when activating the Unsubscribe-Addon, there is an additional notice:
 *     ```wp-block-code
       PHP Deprecated:  The function get_page_by_title is deprecated since version 6.2.0! Use WP_Query instead in [...]/wp-includes/functions.php on line 6031
       ```
   
    -  This reply was modified 2 years, 5 months ago by [newshop](https://wordpress.org/support/users/newshop/).
 *  [CodeWooGeek Support](https://wordpress.org/support/users/codewoogeeksupport/)
 * (@codewoogeeksupport)
 * [2 years, 5 months ago](https://wordpress.org/support/topic/php-deprecated-40/#post-17245114)
 * Hello there,
 * Good Day!!
 * Could you please confirm the version of our plugin “Back In Stock Notifier for
   WooCommerce” you are currently using? If it’s not the latest version, we recommend
   updating to the latest version to see if the issue persists.
 * Additionally, could you please provide a screenshot of the error or more details
   for further analysis?
 * Regarding the Unsubscribe Add-on, we’d like to inform you that support for premium
   plugins is not allowed in this forum. For assistance, kindly contact our dedicated
   helpdesk/visit our website. Our team will be happy to assist you and provide 
   a solution to resolve the deprecated notice.
 * Thanks.
 *  Thread Starter [newshop](https://wordpress.org/support/users/newshop/)
 * (@newshop)
 * [2 years, 5 months ago](https://wordpress.org/support/topic/php-deprecated-40/#post-17245301)
 * Hello,
 * I am using the latest version (5.1.0). Please find a screenshot of my debug.log
   here:
 * [https://ibb.co/0rkcPCH](https://ibb.co/0rkcPCH)
 * As said, when disabling Back in stock notifier, the notice disappears. So I am
   pretty sure that the notice is caused by your plugin.
 * Thank you in advance.
 *  [trektor](https://wordpress.org/support/users/trektor/)
 * (@trektor)
 * [2 years, 5 months ago](https://wordpress.org/support/topic/php-deprecated-40/#post-17300560)
 * Hi, replace content in line number 48 (file wp-content/plugins/back-in-stock-
   notifier-for-woocommerce/includes/frontend/class-product.php) the old line :
 *     ```wp-block-code
       echo do_shortcode( $this->display_subscribe_box( $product, array(), $display_filter ) );
       ```
   
 * with:
 *     ```wp-block-code
       echo do_shortcode( $this->display_subscribe_box( $product, array(), $display_filter ) ?? '');
       ```
   
 *  Thread Starter [newshop](https://wordpress.org/support/users/newshop/)
 * (@newshop)
 * [2 years, 5 months ago](https://wordpress.org/support/topic/php-deprecated-40/#post-17302435)
 * Thank you, that fixed it.
 * [@codewoogeeksupport](https://wordpress.org/support/users/codewoogeeksupport/)
   Can you please include this fix in the next update?
 *  [CodeWooGeek Support](https://wordpress.org/support/users/codewoogeeksupport/)
 * (@codewoogeeksupport)
 * [2 years, 5 months ago](https://wordpress.org/support/topic/php-deprecated-40/#post-17302862)
 * Hello,
 * Thank you for the heads-up, [@trektor](https://wordpress.org/support/users/trektor/).
 * We are pleased to inform you that we will include this fix in our next official
   update, which will be available shortly.
 * Thanks.
 *  [huusoku](https://wordpress.org/support/users/huusoku/)
 * (@huusoku)
 * [2 years, 4 months ago](https://wordpress.org/support/topic/php-deprecated-40/#post-17337080)
 * Thank you [@newshop](https://wordpress.org/support/users/newshop/) for creating
   this error report and [@trektor](https://wordpress.org/support/users/trektor/)
   for the fix. Confirmed working on WP 6.4.2 WC 8.4.0 Back In Stock 5.1.0 PHP 8.1.27

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

The topic ‘PHP Deprecated’ is closed to new replies.

 * ![](https://ps.w.org/back-in-stock-notifier-for-woocommerce/assets/icon-256x256.
   gif?rev=3349374)
 * [Back In Stock Notifier for WooCommerce | WooCommerce Waitlist Pro](https://wordpress.org/plugins/back-in-stock-notifier-for-woocommerce/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/back-in-stock-notifier-for-woocommerce/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/back-in-stock-notifier-for-woocommerce/)
 * [Active Topics](https://wordpress.org/support/plugin/back-in-stock-notifier-for-woocommerce/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/back-in-stock-notifier-for-woocommerce/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/back-in-stock-notifier-for-woocommerce/reviews/)

 * 7 replies
 * 4 participants
 * Last reply from: [huusoku](https://wordpress.org/support/users/huusoku/)
 * Last activity: [2 years, 4 months ago](https://wordpress.org/support/topic/php-deprecated-40/#post-17337080)
 * Status: resolved