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.

Tagged: 

This topic contains 3 replies, has 3 voices.

Last updated by Prosenjit Barman 1 year, 5 months ago.

Assisted by: Prosenjit Barman.

Author Posts
August 11, 2023 at 11:56 am #14188281

QuartixM-6

Hi there,

We have a custom post type called "case studies", and the slug for it is translated via string translation.

Straight after resaving permalinks, it works well. If we edit one of the case studies (not even a content change, just going to the edit screen and clicking update is enough to break the permalinks). The symptom is that the translated slugs don't work and return a 404.

The desired URL structure is as follows - these are just some examples to show that the term case-studies in the URL should be translated for each language/locale:

website.com/case-studies/forest-green-lawn-landscaping/
website.com/fr-fr/temoignages-clients/floriant-express/
website.com/pl-pl/rekomendacje/ringtons-analiza-realizacji/
website.com/es-es/estudios-de-caso/taxis-baena/
website.com/it-it/casi-di-studio/r-g-impianti/

Something triggers a change somewhere, that requires a resaving of permalinks to fix

I haven't disabled other plugins or used a default theme, in case it's a known issue and an easy fix.

Has anybody come across this or similar?

wpml.png
August 11, 2023 at 12:49 pm #14188649

Dražen
Supporter

Languages: English (English )

Timezone: Europe/Zagreb (GMT+01:00)

Hello,

thanks for contacting us.

I am afraid it is not a known issue and should not happen, I assume it is related to some other code or plugin.

Please test if the issue still happens when using only WPML plugins, all other disabled, and WP default theme.

Let us know how it goes.

Regards,
Drazen

August 21, 2023 at 8:42 am #14261133

QuartixM-6

Sorry for the delay in this - I'll be doing some testing today. A fix for another issue we face could also be the fix for this. Once I've done that bugfix, I'll test this again.

August 22, 2023 at 2:38 am #14267447

Prosenjit Barman
Supporter

Languages: English (English )

Timezone: Asia/Dhaka (GMT+06:00)

Hello There,
I hope you're doing well.

Sure! Please test according to the instructions shared by my colleague Drazen. Additionally, ensure that each post type in every language has a distinct slug. As per the guidelines by WordPress, slugs cannot be identical as it can lead to unusual issues on site.

Let us know the update.

Best Regards,
Prosenjit