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.

Sun Mon Tue Wed Thu Fri Sat
- 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 -
- 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 -

Supporter timezone: America/Los_Angeles (GMT-07:00)

This topic contains 15 replies, has 2 voices.

Last updated by Bobby 1 year, 3 months ago.

Assisted by: Bobby.

Author Posts
January 29, 2024 at 11:27 am

camillaB-7

Hi, We have turned off the automatic translations of slug but still its translating the slug automatically when I have added new language.

January 29, 2024 at 12:43 pm
January 29, 2024 at 7:18 pm #15240347

Bobby
WPML Supporter since 04/2015

Languages: English (English )

Timezone: America/Los_Angeles (GMT-07:00)

Hello,

I've set up a sandbox for us to experiment in, as testing in your live environment might be restrictive. Here's the sandbox link: hidden link

Key points to remember:

- With WPML's automatic translation, both content and titles are translated.
- WPML usually auto-generates page URLs from titles (see WPML->Settings->Page URL).
- Since titles are translated, the URL slug changes accordingly (e.g., hidden link becomes hidden link).

In WPML settings, you have two alternatives to this:
1. Use 'Translate' to manually edit URL slugs in the ATE editor. This won't work with automatic translations.

2. 'Copy from original language' for languages with encoded URLs.

for this option to work your language NEEDS to use encoded URLs. (this is why it has not worked when you have tested it so far)

To do this you would have to go to WPML->Languages->Edit languages-> Under dropdown for the language set Encode to Yes.

see here the French translation after setting it to Encode 'Yes' and translating -- even though the title was translated the URL Slug keeps 'tuesday' instead of 'fr-tuesday'

Sandbox link for French: hidden link

Definition of Encode URLS:
https://wpml.org/documentation/getting-started-guide/language-setup/editing-wpmls-languages-table/#language-configuration-fields-defined

January 31, 2024 at 5:35 am #15247276

camillaB-7

1) Ok, I've checked that sandbox and it's working now. My question is that when all the settings are the same as per your suggestions then it will not translate the slug whenever we add new language, right?
2) Is there an option to automatically update the translated slugs for already added languages since there are so many posts on the site that we don't want to manually update the slugs?
3) Does this setting also work for taxonomy and custom post types or do we have to manually update the slug for that?

January 31, 2024 at 6:59 pm #15251345

Bobby
WPML Supporter since 04/2015

Languages: English (English )

Timezone: America/Los_Angeles (GMT-07:00)

1 -- IF you add a new language ffrom WPML->languages-> add language then you will need to go to "edit languages" and set it to "YES" for URL Encode as that feature I mentioned ONLY works with languages that use encoded URLs

2 -- Unfortunately not out of the box , you might be able to find a custom solution to achieve this. I recommend taking a look at the following resources for custom work

https://wpml.org/documentation/support/wpml-coding-api/wpml-hooks-reference/

https://wpml.org/contractors/

3-- That setting is meant for pages and posts, this is our documentation on taxonomy and custom post type slug translation

https://wpml.org/documentation/getting-started-guide/translating-page-slugs/

February 8, 2024 at 7:02 am #15279641

camillaB-7

Can you provide any custom hook that will work for not translating taxonomy slug as I am still facing problem in taxonomy slug translation. I don't want to translate taxonomy slugs.

February 8, 2024 at 8:26 pm #15283340

Bobby
WPML Supporter since 04/2015

Languages: English (English )

Timezone: America/Los_Angeles (GMT-07:00)

I am not familiar with a custom hook that would do this, however, to take a closer look please share with me an example of the taxonomy slugs you have that are being translated.

If you go to WPML->Settings->Post Types are you able to locate your taxonomy there and change manually the slug translation?

February 9, 2024 at 6:04 am #15283987

camillaB-7

I unchecked that option because I don't want to translate the taxonomy slug but it's still translating into the corresponding language. I want the same slug which is in the default language (English). I have attached screenshots of the translated slugs. So I need a solution to not translate the slug anymore because I don't want to manually change the slug every time.

Screenshot 2024-02-09 113109.png
Screenshot 2024-02-09 113032.png
Screenshot 2024-02-09 112428.png
February 9, 2024 at 12:27 pm #15286097

camillaB-7

Can you please provide a solution so that we don't need to manually translate back to EN when a new language is added? If this solution can not be implemented it will impact our SEO when we launch to production, and this is not acceptable.

If we are unable to find a solution we will have no other choice but to find another translation service for our website.

February 9, 2024 at 7:36 pm #15287434

Bobby
WPML Supporter since 04/2015

Languages: English (English )

Timezone: America/Los_Angeles (GMT-07:00)

How are you translating your taxonomies? Are you sending them to the Advanced Translation Editor? If yes, then it is expected for the slug to be translated.

What are your results when manually translating your taxonomies through WPML->Taxonomies Translation?

February 13, 2024 at 5:00 am #15295439

camillaB-7

Yes, I am sending them to advanced translation editor but if I don't go with that then who should I go with so that the taxonomy slug doesn't get translated and we don't want to change the slug manually because changing the slug again and again SEO is affected, that is why we want to keep it automated. So provide solution for that only.

February 14, 2024 at 6:57 pm #15304217

Bobby
WPML Supporter since 04/2015

Languages: English (English )

Timezone: America/Los_Angeles (GMT-07:00)

Hi,

Please disable the 2FA for the dev site so I can login and take a closer look

February 15, 2024 at 9:54 am #15305750

camillaB-7

2FA has been disabled, you should be able to log in now

February 16, 2024 at 1:55 am #15309826

Bobby
WPML Supporter since 04/2015

Languages: English (English )

Timezone: America/Los_Angeles (GMT-07:00)

Looks like I am still blocked on the user provided

Screen Shot 2024-02-15 at 5.55.12 PM.png
February 16, 2024 at 6:49 am #15310067

camillaB-7

now you can check. its working

The topic ‘[Closed] Page slug is getting translated even after setting the "Page URL" to Copy’ is closed to new replies.