How to display child posts in the parent category
You need to use a tax_query with WP_Query. With a tax_query, by default, child terms are included to the term being set. Here is the example- $args = array( ‘post_type’ => ‘post’, // Your post type ‘orderby’ => ‘meta_value_num’, ‘meta_key’ => ‘rankk’, ‘order’ => ‘DESC’, ‘posts_per_page’ => 100, ‘tax_query’ => array( array( ‘taxonomy’ => ‘category’, … Read more