[Resolved] Translated categories not not working/linking correctly
This thread is resolved. Here is a description of the problem and solution.
Problem:
Why do the category links in the German menu redirect to the English category pages instead of the corresponding German pages? (when Rank Math SEO plugin is active).
Background of the issue:
I am using the WPML plugin to manage multilingual content on my WordPress site, specifically for translating and linking categories and menu items between English and German. My default language is set to English, and I am trying to ensure that category links and menu synchronization function correctly across both languages.
Symptoms:
When I click on a German category link from the menu, it redirects to the English category page instead of the German one. Additionally, when synchronizing the menu between languages, the German categories do not appear in the German menu, and unwanted German menu items are added to the English menu, which I then have to manually remove.
Questions:
Why do the category links in the German menu redirect to the English category pages instead of the corresponding German pages?
Why does synchronizing the menu between languages cause unwanted German menu items to appear in the English menu, and why do the German categories not appear in the German menu after synchronization?
I have a small update... Could it be possible that the following setting in RankMath is causing the problem:
Strip Category Base is active in Rank Math
Remove /category/ from category archive URLs. Why do this?
E.g. example.com/category/my-category/ becomes example.com/my-category
Which means all my English category links are displayed like this: hidden link
instead of this: hidden link
But in WPML the taxonomy translation for categories is set to: EN: category --> German: kategorie
PS The problem if I want to deactivate that feature with RankMath it gives me a warning, that it could potentially break the site
That's probably quite possible, because I was just checking our Rank Math page and found some known issue reported by other users (https://wpml.org/plugin/rank-math-seo/ scroll down to find known issues section).
And there are some reported about these options. Please check and if possible carefully apply the solution(s) provided in the erratas.
Please let me know if any of these was helpful, or, I'll keep digging on my end.
Well I hardly guess that this is the issue, but sadly the workaround offered by WPML isn`t working for me as all the categories are already translated.... The workaround suggests not translating the slugs, but that was already done long time ago
So I really don`t know how to fix this
Since categories were already translated, so you don't need to un-translate these. Simply needed to turn off Strip Category Base option in Rank Math → General Settings and clear all caches.
Now hidden link redirects to its German translation hidden link correctly.
sarahS-21 confirmed that the issue was resolved on 2024-05-24 13:02:18.
This ticket is now closed. If you're a WPML client and need related help, please open a new support ticket.