Skip Navigation

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

Problem:
The client is attempting to translate an ACF link field but it is not appearing in the translation editor. The field group is set to 'Expert' and the translation preferences on the field are set to 'Translate'. The client expects to see 'acf/hero/call_to_action' but it's not showing up, even after setting the link field to translate and editing the block, page, and the specific link field.

Solution:
1. Ensure that the ACF field group's translation mode is set to 'Expert'.
2. Set the Link Field to 'Translate'.
3. Edit the block on the original content, save the content, and then attempt to translate it again. This should allow the translation of the link text and its URL.

If the issue persists, it may be due to using the same field names in different blocks. Each field group should have unique field names to avoid conflicts. Prefix each field name properly to ensure that each field name exists only once.

For more guidance, refer to our documentation on translating sites built with ACF:

This requirement for unique field names applies to all fields, including 'headline' and others.

If this solution does not seem relevant to your issue, please open a new support ticket with us.

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

Last updated by Andreas W. 1 year, 3 months ago.

Assisted by: Andreas W..

Author Posts
January 3, 2024 at 6:09 pm

geoffreyS-2

Attempting to translate an ACF link field - in the field group, I have it set to Expert and the translation preferences on the field are "Translate" - but it doesn't show up in the translation editor

I'm seeing acf/hero/headline, but it should also show acf/hero/call_to_action ?

January 3, 2024 at 7:03 pm
January 3, 2024 at 7:31 pm #15148637

Andreas W.
Supporter

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

Timezone: America/Lima (GMT-05:00)

Hello,

Could you please try to search the URL on the Advanced Translation Editor by using this guide and let me know in case this will not solve the issue?

https://wpml.org/documentation/translating-your-contents/advanced-translation-editor/#main-features-of-the-advanced-translation-editor

Hint: Editing "html" to the search field should display all available links on the content.

Best regards
Andreas

January 3, 2024 at 8:29 pm #15148688

Andreas W.
Supporter

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

Timezone: America/Lima (GMT-05:00)

Please take note that we took a look at your site and we can confirm the issue.

I have recreated the issue on a new test site with ACF and WPML and will take further steps for internal escalation.

Once I have feedback from our team I will be in contact with you again.

In case you do not find the time to recreate the issue with a simple example, please let me know and I will give it a try.

January 3, 2024 at 8:33 pm #15148698

geoffreyS-2

Nope, no luck with the URL or label showing up when I do a search in the ATE.

January 4, 2024 at 10:54 am #15150163

Andreas W.
Supporter

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

Timezone: America/Lima (GMT-05:00)

We were able to recreate this issue and have escalated it to our second-tier support team.

It looks as if ACF has made some changes here, which were are not yet covering, but this be able to be solved soon.

Once I receive feedback from our team I will be in contact again.

January 4, 2024 at 11:50 am #15150381

Andreas W.
Supporter

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

Timezone: America/Lima (GMT-05:00)

The issue is that our addon by default copies this link field.

Please go to ACF and edit the field group by setting its translation mode to "Expert".

Then set the Link Field to "Translate".

Now, edit the block on the original content, save the content, and translate it again.

You should now be able to translate the link text and its URL.

January 5, 2024 at 5:29 pm #15155967

geoffreyS-2

I set it to Expert and set the link field to translate, but even when editing the block, page, and even the specific link field, it never shows up on the translate screen.

January 5, 2024 at 5:45 pm #15156030

Andreas W.
Supporter

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

Timezone: America/Lima (GMT-05:00)

The issue is that you are using the same field names in different blocks.

Each field group needs unique field names, as you can not use the same field name twice on Frontend when calling the fields.

You will need to prefix each field name properly so that each field name only exists once.

Guide:
https://wpml.org/documentation/related-projects/translate-sites-built-with-acf/#using-same-fields-across-languages

January 5, 2024 at 6:04 pm #15156125

geoffreyS-2

So "call_to_action" needs to become "hero_call_to_action"? Not sure why that would make a difference but I'd still be able to translate fields like "headline" or "copy" that have the same names across blocks, especially since those fields are scoped in ACF within the specific block.

January 5, 2024 at 6:12 pm #15156128

geoffreyS-2

Just tested this and it does seem to work, but it also means restructuring every single link and call to action on our site. It can be done, but obviously with a huge lift to make it work.

Does this still work if there are multiple blocks on the same page (i.e. text_call_to_action with several text blocks)?

Is there a fix for the missing repeater elements?

January 5, 2024 at 6:13 pm #15156130

Andreas W.
Supporter

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

Timezone: America/Lima (GMT-05:00)

This does count for any field, as well as "headline" and others. They have to have unique names.

From our documentation:
Before you start translating, make sure each of the custom fields across your different field groups have a unique Field Name. If you use the same Field Name with more than one custom field, you may not see all your field values available for translation in the Translation Editor.

Source:
https://wpml.org/documentation/related-projects/translate-sites-built-with-acf/#using-same-fields-across-languages