I’m trying to develop a template that gives a listing of either category titles or post titles, depending on whether the link points to a category that is just a parent of other categories or to a category that has posts.
So far I have the following:
<h2 class="pagetitle"> <?php single_cat_title(); ?> </h2> <div class="list-page"> <ul> <?php wp_list_categories('orderby=name&child_of=4&title_li='); ?> </ul>
Obviously, this works fine for the one category in question, which has none of its own posts but a parent to other categories. I’m at a loss however for how I need to alter this for my desired result.
Thanks for any help.
- The topic ‘Using get_cat_ID’ is closed to new replies.