Skip Navigation

This thread is resolved. Here is a description of the problem and solution.

Problem:

If you're experiencing a fatal error while translating a page or post, specifically a PHP Fatal error indicating 'Uncaught TypeError: strtr(): Argument #1 ($string) must be of type string, array given', this might be due to incorrect translation settings for Themify custom fields.

Solution:

We recommend following these steps to resolve the issue:

1) Navigate to WPML>>Settings>>Custom Fields Translation
2) Click on the System fields link
3) Search for fields by *_themify*
4) Set the *_themify_builder_settings_json* to Don't translate
5) Save the changes

Please ensure to perform a full site backup before making these changes.

If this solution does not resolve your issue or seems irrelevant due to being outdated or not applicable to your case, we highly recommend checking related known issues at https://wpml.org/known-issues/, verifying the version of the permanent fix, and confirming that you have installed the latest versions of themes and plugins. If further assistance is needed, please open a new support ticket at WPML support forum.

This is the technical support forum for WPML - the multilingual WordPress plugin.

Everyone can read, but only WPML clients can post here. WPML team is replying on the forum 6 days per week, 22 hours per day.

Tagged: 

This topic contains 1 reply, has 0 voices.

Last updated by Bigul 1 month, 1 week ago.

Assisted by: Bigul.

Author Posts
March 21, 2025 at 7:57 am #16842892

wannesD

Following a fatal error while translating a page or post

PHP Fatal error: Uncaught TypeError: strtr(): Argument #1 ($string) must be of type string, array given in ****\wp-content\plugins\sitepress-multilingual-cms\classes\utilities\Labels.php:23

March 21, 2025 at 8:23 am #16843019

Bigul
WPML Supporter since 01/2013

Languages: English (English )

Timezone: Europe/Vienna (GMT+02:00)

Hello,

Welcome to the WPML support forum. I will do my best to help you to resolve the issue.

This error is happening because of a wrong translation setting for *Themify* a Custom field. We are getting the expected results in our local copy after the following steps.

1) Visit WPML>>Settings>>Custom Fields Translation
2) Click on *System fields* link
3) Search the fields by *_themify*
4) Choose *Don't translate* option for *_themify_builder_settings_json*
5) Save the changes

Please try it on your site after a full site backup and let us know your feedback. Refer to the attached images for more details.

--
Thanks!

Bigul

2025-03-21_13h02_35.png
2025-03-21_13h01_29.png