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.

This topic contains 8 replies, has 2 voices.

Last updated by Carlos Rojas 1 month, 1 week ago.

Assigned support staff: Carlos Rojas.

Author Posts
September 4, 2019 at 2:35 pm #4512055

katieD-4

I am trying to: Edit the contents of an ACF Gallery field in a translated post.

I expected to see: The same images available in the translated post's gallery field that are available in the default language's version of that post, in the WordPress admin area.

Instead, I got: An empty gallery field.

The gallery images in the translated posts *are* saved in the database, because they display on the front end of the site. They just aren't displaying in the WordPress admin area, so when you next save the post the gallery gets emptied (because you've just saved an empty field).

We are using:
- WordPress 5.2.2
- Advanced Custom Fields Multilingual 1.4.0
- WPML Media 2.5.2
- WPML Multilingual CMS 4.2.7.1
- WPML String Translation 2.8.6.2

We are creating pages in the new languages by duplicating the original language's post, and then setting the duplicate to "translate independently".

Our ACF fields are all set to "Copy once". We have also tried every combination of "Translate", "Copy", "Copy once", and "Do not translate", making sure to also set the relevant system field (the ones prefixed with an underscore). No effect.

The Media Library is correctly populated in all languages, because we've run through the sequence at WPML > Settings > Media Translation.

There's no difference whether we have Advanced Custom Fields Multilingual installed or not - so it's nothing to do with https://wpml.org/errata/issue-serialized-acf-fields-set-copy/.

Our server has high values set for max execution time, max input vars, and memory limits etc. so that's ok.

One important thing we've found is that if we *deactivate the WPML Media plug-in*, this problem does not occur. Unfortunately we can't just remove this plug-in as without it, we lose Featured Images in our translations.

This may be similar to the issues mentioned here https://wpml.org/forums/topic/acf-gallery-wont-copy-images-during-translations/#post-3969603 and here https://wpml.org/faq/acf-post-object-page-link-fields-not-showing-back-end-translated-posts/ - but if so then this is unquestionably a bug, as we're unable to edit the contents of a gallery in a translated post.

Can anyone help please? Thanks.

September 4, 2019 at 2:51 pm #4512277

Carlos Rojas
Supporter

Languages: English (English ) Spanish (Español )

Timezone: America/Montevideo (GMT-03:00)

Hello,
Thank you for contacting WPML support.

1.- I would like to request temporary access (wp-admin and FTP) to your site to take better look at the issue. You will find the needed fields for this below the comment area when you log in to leave your next reply. The information you will enter is private which means only you and I can see and have access to it.

Our Debugging Procedures

I will be checking various settings in the backend to see if the issue can be resolved. Although I won't be making changes that affect the live site, it is still good practice to backup the site before providing us access. In the event that we do need to debug the site further, I will duplicate the site and work in a separate, local development environment to avoid affecting the live site.

2.- Please provide the debug information of the site. In this link you will find the steps to follow: https://wpml.org/faq/provide-debug-information-faster-support/

Kind regards,
Carlos

September 4, 2019 at 3:22 pm #4512503

katieD-4

Hi - due to client confidentiality I can't provide server access at all, sorry.

I've attached a sanitised version of the debug info from my local copy of the site if that helps.

Any chance you could try setting up a local instance of a new site, creating an ACF Gallery in a post in the default language, and then trying to duplicate then translate that post, to see if Gallery images are lost?

Thanks again.

September 4, 2019 at 3:30 pm #4512537

katieD-4

Also thanks for the quick reply.

Can you see the debug info I attached? I can't...

September 5, 2019 at 9:56 am #4518079

Carlos Rojas
Supporter

Languages: English (English ) Spanish (Español )

Timezone: America/Montevideo (GMT-03:00)

Hi,
Thank you very much for your message.

I understand that you can't share access to the site due to confidentiality reasons but unfortunately the debug information provided is not enough.

In this case I created a test site with a fresh new WordPress install and WPML plugins installed and setup. I would like to ask you to log in this site by following this link: hidden link
and install the necessary plugins in order to reproduce the issue.

Could you tell me the results?

Regards,
Carlos

September 8, 2019 at 5:14 pm #4532139

katieD-4

Hi Carlos,

Thanks for setting this up, it has been really helpful 🙂

I've created a barebones example as a test, just using the plug-ins you installed plus ACF Pro (which I've installed).

I've added a post that uses an ACF gallery field - that field and field group are set up exactly as I have them on my site. All ACF fields are set to "Copy Once" in the WPML Settings.

I've uploaded two pictures into the gallery field, then duplicated the post. I then set it to translate independently, and finally I fully translate the post.

In edit view of the English post, you can see the two images:

hidden link

But in French, the Gallery field is empty in edit view (although I'm betting that the images are in the database and available to the theme's code):

hidden link

If I disable the WPML Media plug-in and then view the French post again in Edit mode, the images appear.

I hope this might help you to diagnose what's going on.

Thanks in advance! 🙂

September 9, 2019 at 10:57 am #4536061

Carlos Rojas
Supporter

Languages: English (English ) Spanish (Español )

Timezone: America/Montevideo (GMT-03:00)

Hi there,
Thank you very much for your feedback.

I followed this steps:
- Plugins -> Add New -> Commercial tab -> Downloaded and installed 'Advanced Custom Fields Multilingual' plugin.

Now I can see the gallery images in the edit screen of the French version of the post: hidden link

Please follow the same steps in the live site and let me know if the issue is solved.

Regards,
Carlos

September 9, 2019 at 2:47 pm #4538137

katieD-4

Hi Carlos,

Thanks for checking this - unfortunately we already had Advanced Custom Fields Multilingual installed on our site, and it didn't have any effect.

I'm going to check again to see if I can see any difference between our set-up and yours. There must be something. Will get back to you.

Thanks!

September 9, 2019 at 3:47 pm #4538729

Carlos Rojas
Supporter

Languages: English (English ) Spanish (Español )

Timezone: America/Montevideo (GMT-03:00)

Hi,

Thank you for keeping me updated.

Regards,
Carlos