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.
Elementor users - please update WPML to the latest version to maintain compatibility. More details here - https://wpml.org/changelog/2024/12/wpml-4-6-15-critical-update-for-elementor-sites/
Background of the issue:
I am trying to translate a custom post type (CPT) 'author' into Croatian using WPML with the 'Translatable (use translation if available or fallback to default language)' option. The original slug is 'author', and I'm translating it to 'autor'. The CPT is registered with a plugin, and here is the code for that: hidden link. I am using WPML plugins and the Twenty Twenty-One theme with no modifications. I have another ticket open which is not related to this: https://wpml.org/forums/topic/translate-cpt-slug/. The issue can be seen here: hidden link
Symptoms:
The permalink for the Croatian version of the post is 'hidden link' instead of 'hidden link'. The word 'author' is not translated to 'autor', although the language switcher in the footer uses the correct link.
Questions:
Why is the slug 'author' not translating to 'autor' in the permalink?
How can I ensure the translated slug appears correctly in the permalink?
I've reviewed the report status, and I can confirm it’s on our dev team’s to-do list. Unfortunately, I don’t have any updates or workarounds at this time, but I’ll definitely get back to you as soon as I have feedback.
We have a solution and this is how it works now hidden link . You'll notice that the permalink for the Croatian version of the post is now using hidden link
To fix this, navigate to wpml-string-translation/classes/slug-translation/class-wpml-slug-translation.php line 129
Hey Kor. Thank you for the fix. I can confirm it's working. Do you know when will the change go in to WPML String Translation? I'm asking just so we know so if the next version doesn't have the fix it that we add it back in after we update the plugin.