Custom post type and custom taxonomies under same slug?
-
Hi,
I have a pretty complex question about Custom Post Types and Taxonomies.
We have a Custom Post Type for our case studies, which is set up as follows:
Post Type Slug: content_market
Custom Rewrite Slug: work
As a result, these case studies have URLs as follow:
example.com/work/case-study-1, example.com/work/case-study-2,
etc.Now I’m supposed to create categories (or hubs) for these case studies, and achieve this structure:
example.com/work/animation/
example.com/work/ecommerce/
etc.The case studies URLs should remain the same, but each one of these post will be included in one (or more) hub.
How would you approach this? Should I create a new Taxonomy for the case studies? If so, how do I make these taxonomy URLs to be under /work?
if I create a Taxonomy with Custom Rewrite Slug: work and Rewrite: true then it does seem to create these categories (like example.com/work/animation works fine), but it then breaks regular CPT posts (such as example.com/work/case-study-1).
Would you know how I should set this up?
Thanks in advance!
- The topic ‘Custom post type and custom taxonomies under same slug?’ is closed to new replies.