Event Category URL Translation Redirects to 404 Pages
-
Hello,
I’m using The Events Calendar together with TranslatePress.
I’m experiencing issues with event category URLs when using a secondary language.
For example, on single event pages, the category link works correctly in the default English version:/events/category/concerts/
However, in other languages, the category base gets translated (for example to “categoria”), and the URL becomes something like:/events/es/categoria/concerts/
These URLs lead to a 404 page because such routes do not exist.
On single event pages, the category links point to these non-existing translated URLs, so users are redirected to 404 pages when clicking them.
Everything works correctly if the category base remains “category”, for example:/events/es/category/concerts/
Screenshot from a single event page in German: https://ibb.co/0ysrDpLd When hovering over the event category link “Concert”, the browser shows that the link points to: /de/events/kategorie/concerts/. So the category base is translated from “category” to “kategorie”. This translated URL leads to a 404 page. The working structure would be: /de/events/category/concerts/ .
So the issue occurs when the category base is translated.
My translation setup is based on .po/.mo files from your official translations:https://translate.wordpress.org/projects/wp-plugins/the-events-calendar/stable/
I have not seen this issue with other plugins I use.
Could this be related to how The Events Calendar defines or registers its taxonomy base or slugs, or possibly to the translation files?
Is there a recommended way to prevent the category base from being translated, or to properly support multilingual category URLs?
Thank you for your support.
Kind Regards
You must be logged in to reply to this topic.