I have a category structure like this...
- Shirts
- Small
- Red
- blue
- green
- Medium
- Large
- Jackets
- Hats
...where the ID of 'Shirts' is 1. When I do this...
<ul>
<?php
query_posts('cat=1&showposts=10&order=ASC');
if (have_posts()) : while (have_posts()) : the_post(); ?>
<li>
<a href="<?php the_permalink() ?>"><?php the_title(); ?></a>
</li>
<?php endwhile; else: ?>
<?php _e('Nothing Here!'); ?>
<?php endif; ?>
</ul>
... instead of showing just the children of Shirts, it is also showing the grandchildren. To illustrate, the output on the screen is showing Small, red, blue, green Medium and Large ,instead of just Small, Medium and Large.
How can I exclude the grandchildren?
Thanks in advance.