Skip Navigation

[Resolved] preg_match() and strlen() errors coming from Toolset – Fix needed

This support ticket is created 4 years, 7 months ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Sun Mon Tue Wed Thu Fri Sat
- 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 -
- 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 -

Supporter timezone: Asia/Kolkata (GMT+05:30)

This topic contains 2 replies, has 2 voices.

Last updated by MichaelR9215 4 years, 7 months ago.

Assisted by: Minesh.

Author
Posts
#1594907
pmedc.JPG

Hello,

There are two major errors on one of my client websites. This issue seems to have occurred after I updated the website to the newest WP Core, as well as updated all plugins.

The following is a trace back from the errors to their sources:

WARNING: wp-includes/class-wp-block-parser.php:417 - preg_match() expects parameter 2 to be string, array given
require('wp-admin/edit-form-blocks.php'), do_action('enqueue_block_editor_assets'), WP_Hook->do_action, WP_Hook->apply_filters, Toolset\DynamicSources\DynamicSources->register_localization_data, apply_filters('toolset/dynamic_sources/filters/get_dynamic_sources_data'), WP_Hook->apply_filters, Toolset\DynamicSources\DynamicSources->get_dynamic_sources_data, apply_filters('toolset/dynamic_sources/filters/cache'), WP_Hook->apply_filters, Toolset\DynamicSources\Cache->add_cached_data, call_user_func_array, Toolset\DynamicSources\Cache->get_data_for_sources, apply_filters('toolset/dynamic_sources/filters/get_source_content'), WP_Hook->apply_filters, Toolset\DynamicSources\DynamicSources->get_source_content, Toolset\DynamicSources\Sources\MediaFeaturedImageData->get_content, wp_kses_post, wp_kses, wp_kses_hook, apply_filters('pre_kses'), WP_Hook->apply_filters, wp_pre_kses_block_attributes, filter_block_content, parse_blocks, WP_Block_Parser->parse, WP_Block_Parser->proceed, WP_Block_Parser->next_token, preg_match
WARNING: wp-includes/class-wp-block-parser.php:489 - strlen() expects parameter 1 to be string, array given
require('wp-admin/edit-form-blocks.php'), do_action('enqueue_block_editor_assets'), WP_Hook->do_action, WP_Hook->apply_filters, Toolset\DynamicSources\DynamicSources->register_localization_data, apply_filters('toolset/dynamic_sources/filters/get_dynamic_sources_data'), WP_Hook->apply_filters, Toolset\DynamicSources\DynamicSources->get_dynamic_sources_data, apply_filters('toolset/dynamic_sources/filters/cache'), WP_Hook->apply_filters, Toolset\DynamicSources\Cache->add_cached_data, call_user_func_array, Toolset\DynamicSources\Cache->get_data_for_sources, apply_filters('toolset/dynamic_sources/filters/get_source_content'), WP_Hook->apply_filters, Toolset\DynamicSources\DynamicSources->get_source_content, Toolset\DynamicSources\Sources\MediaFeaturedImageData->get_content, wp_kses_post, wp_kses, wp_kses_hook, apply_filters('pre_kses'), WP_Hook->apply_filters, wp_pre_kses_block_attributes, filter_block_content, parse_blocks, WP_Block_Parser->parse, WP_Block_Parser->proceed, WP_Block_Parser->add_freeform

This seemed to have caused my client issues with not being able to edit any pages or posts. I refreshed the salts, and she is able to edit again, but these errors remain.

Please advise.

#1595405

Minesh
Supporter

Languages: English (English )

Timezone: Asia/Kolkata (GMT+05:30)

Hello. Thank you for contacting the Toolset support.

First of all - After checking the debug information you shared with us, I found that you are using outdated Toolset plugins. We always recommend running your site with the latest stable release plugin version.

The current version of Toolset Types plugin is 3.3.10 and Views plugin is 3.1.3.

*** Please make a FULL BACKUP of your database and website.***
Could you please update ALL Toolset plugins to it's latest officially released version. You can download the latest plugin release from your accounts page:
=> https://toolset.com/account/downloads/
*** Please make a FULL BACKUP of your database and website.***

#1595737

For some reason, the updates were not showing in my dashboard. I had to deregister Toolset, and re-register. After that, the updates showed.

I made these updates, and there are no longer errors.

Thank you.