custom-post-type-permalinks
custom-post-type-permalinks copied to clipboard
Custom taxonomy archive with WPML broken
Hi @torounit
We came across an issue when custom permalink of custom taxonomy archive is active using in combination with WPML
We created a CPT "Work" and a associated a custom taxonomy "Services". The main language is german, secondary english.
Now we created two Projects in the CPT works (including translations) and added a different service taxonomies to each one.
Here you can access the archive pages: http://serious-seahorse-ek7qx0y9.sandboxcms.com/arbeit/ http://serious-seahorse-ek7qx0y9.sandboxcms.com/en/work/
Now with the Custom Post Type Permalinks plugin we filter by taxonomy like this: http://serious-seahorse-ek7qx0y9.sandboxcms.com/en/work/service/brand-identity/ (returns two projects) http://serious-seahorse-ek7qx0y9.sandboxcms.com/en/work/service/packaging/ (returns one project) As you can see this works in the translated english version of the site.
But for some reason not in the main language, we get 404: http://serious-seahorse-ek7qx0y9.sandboxcms.com/arbeit/leistung/markenidentitaet/ http://serious-seahorse-ek7qx0y9.sandboxcms.com/arbeit/leistung/verpackung/
Is there any way this could be fixed?
Thanks, Aldo
Originally posted by @abombelli in https://github.com/torounit/custom-post-type-permalinks/issues/98#issuecomment-760109576
@torounit Did you had a chance to look into it? Let me know if you need anything.
@torounit It has been a while, and the links added are not valid anymore. But did you had a chance to check the issue?
@abombelli hello, Have you tried any of the solutions mentioned in the WPML forum?
https://wpml.org/forums/topic/custom-post-type-permalinks-compatibility/#post-7785229
Our compatibility developers are already looking in to all possibilities to make it work. As of now you should consider disabling the feature, custom taxonomy permalink in Settings > Permalinks (If you check this, the custom taxonomy's permalinks will be) which is conflicting with WPML
I'm not familiar with WPML, so I don't know, but I think you need to disable the ability to change taxonomy permalinks.
And I think the solution is to set slug
for register_taxomomy
.