I want to start implementing WPML soon, but it’s not clear to me in which language I need to write all labels.
I know template/plugin files need to be in English, but I can’t find if it matter if labels are in a localised language (Dutch).
Hi @beee
The labels should follow the current language you use on your site (the default language). Also, I suggest you use English for the field name.
To learn more about translating custom fields, please check this page: https://www.advancedcustomfields.com/resources/multilingual-custom-fields/.
I hope this helps 🙂
Thanks, field names are always English. My site will most likely be in Dutch.
I read through all the docs on ACF and WPML and since it was written in the WMPL docs that all template strings should be in English, I was doubting, since I echo all the field labels manually in my template… Hence…
The field names are only shown when a user adds/edits a post (through the front-end).
Knowing this, would you still advise to do it in Dutch or does this change it ?
Hi @beee
The purpose of translating custom fields is so when you select certain languages, the label will be changed to the chosen language automatically. But this won’t change the field name (as long as you don’t translate the field name).
So, if your current language (on wp-admin) is Dutch, you can set the labels in Dutch, and if your current language is English, you can set them to English.
If you don’t want this behavior, you can always disable the translation for custom fields.
I hope this makes sense 🙂
I think so 🙂
And if I echo the field labels manually in my template they should be in english right, because they’re template tags ?
Hi @beee
If you echo the label manually, it should be in English. But I suggest you use WordPress localization feature so it will be translated when your visitors are seeing the Dutch page. This page should give you more idea about it: https://codex.wordpress.org/I18n_for_WordPress_Developers.
I hope this helps 🙂
I assume you mean
__($string, 'textdomain')
instead of ‘just’ an English string ?
when I say I echo my names in the templates, I meant of course properly prepared for translation…
Hi @beee
I am sorry for the delayed response.
Yes, I meant using something like that.
Hope this clears things up 🙂
The topic ‘Which language do I need to use for labels when using WPML’ is closed to new replies.
Welcome to the Advanced Custom Fields community forum.
Browse through ideas, snippets of code, questions and answers between fellow ACF users
Helping others is a great way to earn karma, gain badges and help ACF development!
We use cookies to offer you a better browsing experience, analyze site traffic and personalize content. Read about how we use cookies and how you can control them in our Privacy Policy. If you continue to use this site, you consent to our use of cookies.