So I’m trying to query posts that are in a child category name Website Development Portfolio. I can query posts in the parent category just fine like so. If I enter ‘Website Development Portfolio’ instead of ‘Portfolio’ then the query returns all posts. How can I return only the posts in the child category?
Can it be that using a category name with spaces interprets as “Website+Development+Portfolio”?
Have you also tried to use the “category id” for the child category ‘Website Development Portfolio’?
Have you tried using the tag for that category:
“Display posts that have this tag, using tag slug”:
$query = new WP_Query( array( 'tag' => 'cooking' ) );
Or Simple Taxonomy Query:
“Display posts tagged with bob, under people custom taxonomy”: