The issue was noticed thanks to Query Monitor plugin. Using it, you will likely be able to see the PHP deprecation upon using Gutenify plugin.
It appears the issue resides in wp-content/plugins/gutenify/core/inc/class-block-inline-styles.php
that returns a null parameter to a string, which would be deprecated by PHP 8. That is my understanding as a sysadmin, I’m no PHP dev, so a direct look at the error will surely help you better understand the issue.
So here is what Query Monitor reveals:
stripos(): Passing null to parameter #1 ($haystack) of type string is deprecated
wp-includes/functions.wp-styles.php:90
stripos()
wp-includes/functions.wp-styles.php:90
wp_add_inline_style()
wp-content/plugins/gutenify/core/inc/class-block-inline-styles.php:34
Gutenify_block_inline_styles::add_inline_styles()
wp-includes/class-wp-hook.php:324
do_action('wp_enqueue_scripts')
wp-includes/script-loader.php:2263
wp_enqueue_scripts()
wp-includes/class-wp-hook.php:324
do_action('wp_head')
wp-includes/general-template.php:3065
wp_head()
wp-includes/template-canvas.php:17
1 Extension : gutenify
I hope this is useful in some way! And I remain available if further details are required to help diagnose and resolve the issue.
Best regards
]]>PHP Deprecated: ?Creation of dynamic property IGFW\Helpers\Plugin_Constants::$_MAIN_PLUGIN_FILE_PATH is deprecated in /var/www/html/wp-content/plugins/invoice-gateway-for-woocommerce/Helpers/Plugin_Constants.php on line 53
PHP Deprecated: ?Creation of dynamic property IGFW\Models\Gateways\IGFW_Invoice_Gateway::$instructions is deprecated in /var/www/html/wp-content/plugins/invoice-gateway-for-woocommerce/Models/Gateways/IGFW_Invoice_Gateway.php on line 38
PHP Deprecated: ?Creation of dynamic property IGFW::$failed_dependencies is deprecated in /var/www/html/wp-content/plugins/invoice-gateway-for-woocommerce/invoice-gateway-for-woocommerce.php on line 158
Subsequently this is generating deprecation errors when preg_replace is called with null as a parameter to $subject.
PHP Deprecated: preg_replace(): Passing null to parameter #3 ($subject) of type array|string is deprecated in /var/www/html/wp-includes/kses.php on line 1805
Can we please make sure all properties of the classes are defined else allow dynamic properties in all classes?
Thanks
]]>PHP Deprecated: ?Creation of dynamic property IGFW\Helpers\Plugin_Constants::$_MAIN_PLUGIN_FILE_PATH is deprecated in /var/www/html/wp-content/plugins/invoice-gateway-for-woocommerce/Helpers/Plugin_Constants.php on line 53
PHP Deprecated: ?Creation of dynamic property IGFW\Models\Gateways\IGFW_Invoice_Gateway::$instructions is deprecated in /var/www/html/wp-content/plugins/invoice-gateway-for-woocommerce/Models/Gateways/IGFW_Invoice_Gateway.php on line 38
PHP Deprecated: ?Creation of dynamic property IGFW::$failed_dependencies is deprecated in /var/www/html/wp-content/plugins/invoice-gateway-for-woocommerce/invoice-gateway-for-woocommerce.php on line 158
Subsequently this is generating deprecation errors when preg_replace is called with null as a parameter to $subject.
PHP Deprecated: ?preg_replace(): Passing null to parameter #3 ($subject) of type array|string is deprecated in /var/www/html/wp-includes/kses.php on line 1805
Can we please make sure all properties of the classes are defined else allow dynamic properties in all classes?
Thanks
]]>Deprecated: Creation of dynamic property Custom_Layouts\Admin::$should_regenerate_css is deprecated in /Users/{user}/Sites/{sitename}/wp-content/plugins/custom-layouts/includes/class-custom-layouts-admin.php on line 65
Deprecated: Creation of dynamic property Custom_Layouts::$integrations is deprecated in /Users/
{user}/Sites/{sitename}
/wp-content/plugins/custom-layouts/includes/class-custom-layouts.php on line 312
Many thanks
]]>Deprecated: Creation of dynamic property SiteOrigin_Settings::$loc is deprecated in /Users/{user}/Sites/{sitename}/wp-content/themes/vantage-child/inc/settings/settings.php on line 36
Many thanks
]]>We received the following PHP error when updating the plugin:
An error of type E_ERROR was caused in line 258 of the file /xxxxxxx/public_html/sandbox/wp/wp-content/plugins/wp-asset-clean-up/classes/PluginReview.php. Error message: Uncaught Error: Class "WpAssetCleanUp\MiscAdmin" not found in /xxxxxxx/public_html/sandbox/wp/wp-content/plugins/wp-asset-clean-up/classes/PluginReview.php:258
Stack trace:
#0 /xxxxxxx/public_html/sandbox/wp/wp-content/plugins/wp-asset-clean-up/classes/PluginReview.php(118): WpAssetCleanUp\PluginReview->showReviewNotice()
#1 /xxxxxxx/public_html/sandbox/wp/wp-includes/class-wp-hook.php(324): WpAssetCleanUp\PluginReview->noticeScripts()
#2 /xxxxxxx/public_html/sandbox/wp/wp-includes/class-wp-hook.php(348): WP_Hook->apply_filters()
#3 /xxxxxxx/public_html/sandbox/wp/wp-includes/plugin.php(517): WP_Hook->do_action()
#4 /xxxxxxx/public_html/sandbox/wp/wp-admin/includes/template.php(2222): do_action()
#5 /xxxxxxx/public_html/sandbox/wp/wp-admin/update.php(53): iframe_footer()
#6 {main}
thrown
Also it appears that the plugin seems to be generating PHP deprecation notices:
PHP Deprecated: strpos(): Passing null to parameter #1 ($haystack) of type string is deprecated in /xxxxxxx/public_html/sandbox/wp/wp-includes/functions.php on line 7300
PHP Deprecated: str_replace(): Passing null to parameter #3 ($subject) of type array|string is deprecated in /xxxxxxx/public_html/sandbox/wp/wp-includes/functions.php on line 218
## Some additional background information
WordPress version 6.6.2
Current plugin: Asset CleanUp: Page Speed Booster (version 1.3.9.7)
PHP version 8.2.23
Using a custom theme
Disabling the plugin seems to get rid of the PHP deprecation notice, though we can’t pinpoint its origin with the plugin itself since it’s coming from core WP functions.
Any advice that you can provide would be appreciated. We can provide additional information — link to site, etc directly.
]]>Upon switching to PHP 8.4.0 and running Query Monitor, we ran into this deprecation notice:
Return type of MailPoetVendor\Carbon\Traits\Date::createFromTimestamp($timestamp, $tz = null) should either be compatible with DateTime::createFromTimestamp(int|float $timestamp): static, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice
Fix appreciated.
Thank you!
]]>I’ve patched 1.20 on the WordPress multisite this is being used on, and just re-applied the same patch to 1.21. Is there any chance this can get included in the codebase?
// file ./wp-content/plugins/mammoth-docx-converter/mammoth-editor.js
// Lines 185 to 187
// SK core/editor removed in 6.2, use core/block-editor instead
var block = wp.blocks.createBlock("core/freeform", {content: text});
wp.data.dispatch("core/block-editor").insertBlocks(block);
Thanks!
Sandra.
]]>