Can’t display Project CPT category
-
Hi. I’m trying to show a sidebar list of a certain category of posts within a custom post type. An example URL that points to such a category is:
https://mysite.com/project_category/video/
However, when I use this code:
[display-posts taxonomy=”project_category” tax_term=”video”]
Nothing displays. (And yes there is a “video” category. I’ve tried “Video” as well though I didn’t think capitalization mattered…)
The “project” category is created within the Divi Builder, of which I’m using a child theme – but I did locate the code where the Projects CPT is created, and the line where it’s registered looks like this:
register_taxonomy( 'project_category', array( 'project' ), $project_category_args );
So why does my shortcode not work?
(I have been able to successfully use a Display Posts shortcode elsewhere on my site to show a different custom post type, LearnDash online courses – after locating their fairly obscure CPT taxonomy name online. So I figure it must be something simple I’m getting wrong here… but what?)
Hope someone can point me in the right direction. Thanks!
- The topic ‘Can’t display Project CPT category’ is closed to new replies.