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

Last updated by lucaC-64 5 months ago.

Assigned support staff: Raja Mohammed.

Author Posts
May 20, 2019 at 8:42 am #3844943

lucaC-64

I am trying to: I've created an ACF custom field for posts where, in the backend, I set some info to filter the post in the front end.

No problem with the main language (italian) but if I make a post in another language or translate a post, that custom field doesn't appear (even if it seems that it takes the info from the original post, in case i'm translating). I need to be showing.

What I have to do?

May 20, 2019 at 10:00 am #3845841

Raja Mohammed
Supporter

Languages: English (English )

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

Hi there,

I'm not sure about your setup and plugins installed, Could you please help me with the WPML debug information please refer https://wpml.org/faq/provide-debug-information-faster-support/

I'm understanding it as Custom field is not appearing in the backend for the secondary language, this might happen if the custom fields are set to Don't Translate which is the default translation preference if you have not changed it during the creating of custom fields.

Please refer to the documentation regarding setting the translation preference for ACF fields. https://wpml.org/documentation/related-projects/translate-sites-built-with-acf/#reviewing-the-translation-preference-after-updating-to-acfml-1-1

Make sure the field is set to translate if you prefer the fields to be available in the translation of the post.

Once you have changed the preference, Please update the original post so that the fields can be visible in the translation.

Please let me know if this helps.

Kind regards
Raja

May 20, 2019 at 12:20 pm #3846659

lucaC-64

Hi! I've added debug informations.
Also, from Setting I've put "Field group" as translatable. But still not showing in other language except the main (italian)

May 20, 2019 at 12:22 pm #3846677

Raja Mohammed
Supporter

Languages: English (English )

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

Please share temporary access to the site, Share the URL where the issue can be seen,
I have enabled private fields for you to securely share the details.

Kind regards
Raja

May 21, 2019 at 5:51 am #3852021

Raja Mohammed
Supporter

Languages: English (English )

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

HI there,

Please install "Advanced Custom Fields Multilingual" plugin to make the Custom fields work with WPML translation. Once the plugin is installed you can set translation preference for each field in the field group make sure the fields are set to translate.

Please follow the instruction in the documentation https://wpml.org/documentation/related-projects/translate-sites-built-with-acf/#setting-the-translation-preference-for-simple-fields

BTW please change the Field group translation preference as Don't translate from WPML > Settings.

Please let me know the results.

Kind regards
Raja

May 21, 2019 at 9:35 am #3853611

lucaC-64

Hi Raja, thanks for your help! Now it works. Still I don't understand how to translate, now, the fields itself! I mean, in one field i have the option "Tour da 1 giorno" "Tour da 2 giorni" and I need to translate them in "1 day tour", "2 days tour" and so on. Where can i do that now?

May 21, 2019 at 2:06 pm #3856063

Raja Mohammed
Supporter

Languages: English (English )

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

Glad it solved your initial issue,

I think your current request is to translate the options.
Please follow the steps here https://wpml.org/documentation/related-projects/translate-sites-built-with-acf/#translating-field-groups

Once you have created the translation of field group you can update the translated options

I hope this helps you better, let me know if you need further assistance.

Kind regards
Raja

May 21, 2019 at 2:22 pm #3856139

lucaC-64

In that way I can translated them, but i have to translate them every time. I need to have a version of the ACF setted and usable.

Also right now I have the WPML advanced editor activated. Using divi theme i need to be able to edit the page as i did before, how can i disable the advanced editor and go back?

May 22, 2019 at 8:28 am #3863025

Raja Mohammed
Supporter

Languages: English (English )

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

Sorry, I don't get the exact essence of what you mean by you have to translate every time, You can add the translation once for each language then it will appear in the backend. or is there something else you want help with?

To disabled Advanced editor go to WPML > Settings > How to translate posts, select the option "Use WPML's Classic Translation Editor"

If you prefer to use divi builder for translation in post edit page on the right languages widget turn off WPML editor switch above the translation (refer screenshot)

Kind regards
Raja

May 22, 2019 at 9:26 am #3863739

lucaC-64

Hi Raja, I'm sorry if I wasn't clear enough. I'll try to explain step by step what I'm doing in order to let you understand what the issue is.

Let's start saying that my main language is Italian, and I've enabled the advanced translator by WPML.
I have a create a custom field called "ricerca", inside them there are 2 fields, "Zona" (which contains the options "Nord" "Centro" "Sud" "Isole") and "Durata del tour" (which contains options "Tour di 1 giorno" "Tour di 2 o 3 giorni" and "Tour maggiori di 3 giorni"). This ACF Field appears in posts backend, and is used to filter, in the front end, the post.

With Italian it works all fine.

Now, let's say that I want to create a brand new post in English (so it's not the translation of anything). Fromt he top bar I select the english flag, i go to post=> add new.
Now, below the post, I have the section for the custom field "Ricerca" with the two fields (Zona/Durata del Tour) and the options. Everything is in italian. I need it to be in english.

Now, let's say that I want to translate a post from ITA to ENG.
I go to the post list, i click ont he gears icon (is a page that was already trasnlated) and in this page i find also the translations of the field. But the only fields that i can translate are the 2 option used in the italian version of the post (for example "Nord" and "Tour di 2 o 3 giorni", as you can see in the screenshot). I need to be able to translate all the voices once and have already translated even if I'm not using the advanced WPML editor.

Hope it's clear now.
Is it possible to do what i need?

May 22, 2019 at 2:22 pm #3866611

Raja Mohammed
Supporter

Languages: English (English )

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

Okay, I think I get this now.

Please Follow the steps:

- Goto WPML > Setttings > Post type translation select "Translate - only.." option for post type "Field Group"

- In Custom fields Edit the field group, Change the option for the field durata_del_tour as name : value pairs like
tour1 : Tour di 1 giorno
tour2 : Tour di 2 o 3 giorni
tour3 : Tour maggiori di 3 giorn

Set the field Translation preference to "Copy"

Update the field group

- Duplicate the field group to any of the translation, and select the Edit Independently button

- In the translation of the field, group translate the "durata_del_tour" option values as

tour1 : Translation of tour 1
tour2 : Translation of tour 2
tour3 : Translation of tour 3

Make sure the part on the left remains the same as it is in the primary language.

This will help you display translated values for each post with out manually translating them.

I hope this helps you better, Let me know if you need further assistance.

Kind regards
Raja

May 22, 2019 at 2:41 pm #3866803

lucaC-64

My issue is resolved now. Thank you!

May 22, 2019 at 2:47 pm #3866837

lucaC-64

Sorry, another question I'm doing the same thing for the field Zona. It works but for this one, i don't know why, it appears as "zona3: South". What do I have to do to not show "zona3"?

I mean, for the other field i have tour1/tour2/tour3 but doesn't appear.

Thanks!

May 22, 2019 at 2:55 pm #3866895

Raja Mohammed
Supporter

Languages: English (English )

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

There should be a space before and after the :

It should be zona3 : South

Kind regards
Raja

May 23, 2019 at 7:03 am #3871759

lucaC-64

Oooops, my fault! It works now! Thank you again for you support!