title: show Wordpress posts under subcategory only, not category
body: <p>I am using this code to display subcategory in a category</p>
  
  <pre><code>&lt;?php $this_category = get_category($cat);
  
      $id = get_query_var('cat');
      $args = array(  'parent' =&gt; $id );
      $catdesc = $cat-&gt;category_description;
      foreach (get_categories($args) as $cat) 
  :?&gt;
  &lt;a href="&lt;?php echo get_category_link($cat-&gt;term_id); ?&gt;"&gt;
  &lt;?php echo ("$cat-&gt;cat_name"); ?&gt;&lt;/a&gt;
  
      &lt;?php endforeach ?&gt;     
  
      &lt;?php while ( have_posts() ) : the_post(); ?&gt;
  
      &lt;?php
          get_template_part( 'content/content', get_post_format() );
      ?&gt;
  
      &lt;?php endwhile; ?&gt;
  </code></pre>
  
  <p>The problem is that all the posts in the category display under the category and the subcategory.</p>
  
  <p>But i want to display posts under that subcategory only, not in category.</p>