Skip Navigation

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 2 replies, has 2 voices.

Last updated by kevinB-5 1 year, 6 months ago.

Assisted by: Long Nguyen.

Author Posts
June 2, 2023 at 9:35 am #13760209

kevinB-5

I have installed:
- WPML Multilingual CMS (4.6.3)
- Advanced Custom Fields Pro (6.1.6)
- Advanced Custom Fields Multilingual (2.0.5)

I configured a secondary language. Now I want to make all Options pages translatable, so I configure all options to 'copy', 'copy once' and so on. After doing this, I duplicated the options page to the secondary language. Everything works.

But now, if I want to make a change to the fields for the primary language and save, I get the following fatal error:
"Fatal error: Uncaught Exception: item should be a Collection or an array or an object
in /Users/Dominique/Local/studio-figments/app/public/wp-content/plugins/sitepress-multilingual-cms/vendor/wpml/fp/core/Obj.php on line 112"

June 6, 2023 at 2:25 am #13774885

Long Nguyen
Supporter

Languages: English (English )

Timezone: Asia/Ho_Chi_Minh (GMT+07:00)

Hi Kevin,

Thank you for contacting WPML support, I'd be happy to help you with this issue.

Checking the debug info, I see there are some issues, please fix it and check the issue again to see how it goes.

1.
- Go to ACF > Switch the language to Dutch with the language switcher at the topbar.
- Delete all field groups in the Dutch language.
- Go to WPML > Settings > Post Types Translation > Set the post type "acf-field-group" to Not Translatable.

2. Increase WP memory limit: The minimum requirements are 128M, but we do recommend 256M and the debug information of your site shows it set to 40M. Please check this link for more details
https://wpml.org/home/minimum-requirements/.
You can increase it by adding the following code in your wp-config.php file, right before the /* That’s all, stop editing! Happy publishing. */ line:


define( 'WP_MAX_MEMORY_LIMIT', '256M' );
define( 'WP_MEMORY_LIMIT', '128M' );

After adding the code you can confirm that the memory was changed correctly from WPML > Support > WordPress > Memory limit.

3. Install and activate the plugin WPML String Translation.

❌ IMPORTANT: Please backup your database and website before proceeding ❌

Refer documentation https://wpml.org/documentation/related-projects/translate-sites-built-with-acf/

Look forward to your reply.
Thanks

June 6, 2023 at 9:43 am #13777191

kevinB-5

Hi Nguyen,

As per the other topic (https://wpml.org/forums/topic/distributing-fields-with-acf-json/) about the same site, I have changed the translate setting and this problem now no longer occurs.