How do you change the 'Category Base' name for just one Custom Post Type Category, without a Plugin?
I currently have my permalinks set up as:
example.com/%postname%/
with the Category Base name of "topic".
I have created some custom post types for resource types:
Article (posts that are articles)
Infographic (posts that are infographics)
These custom post types share the taxonomy named "category" which these can be selected inside the post edit area:
Growth
Change
The permalinks display the shared Category Archives exactly how I want:
Main Category Archive Permalinks:
example.com/topic/Growth
example.com/topic/Change
And the Resource Type Archives exactly how I want:
example.com/article/
example.com/infographic/
The Single page Permalinks also display how I want:
example.com/article/nameofthepost/
example.com/infographic/nameofthepost/
The unique one I want to change is a CPT called "Events" with its own categories:
In Person
Virtual
The Single Event Permalink is fine:
example.com/events/test-event/
But the Events Category Archive still has the "topic" Base name:
example.com/topic/in-person/
How can I change that to be "events" instead of "topic"?
example.com/events/in-person/
source https://stackoverflow.com/questions/68967121/unique-permalink-for-custom-post-type-archive
Comments
Post a Comment