See the process of creating a taxonomy and tell me where I made a mistake
You shouldn’t be doing this: $searchProductsByCategory = [ ‘posts_per_page’ => 1, ‘post_type’ => ‘product’, ‘ignore_sticky_posts’ => 1, ‘orderby’ => ‘id’, ‘tax_query’ => [ [ ‘taxonomy’ => ‘product_category’, ‘terms’ => get_queried_object_id() ] ] ]; $foundProducts = new WP_Query($searchProductsByCategory); The whole point of taxonomy-product_category.php is that posts for the current category have already been queried. This is … Read more