“this month’s categories”
-
I’ve seen tons of posts about having category archive by month and tried to sort a solution from there but I wasn’t able to… what I want is somehow similar: listing all categories that have one or more posts this (or any) month.
What I’ve done so far:`[…]<?php if (is_category() && is_month()){?>
<h2 class=”pagetitle”>Archive for the ‘<?php single_cat_title(); ?>’ Category from <?php the_time(‘F, Y’); ?></h2><?php } ?>[…]`this allows you to enter an URL of the form /?m=200707&cat=1 and it does list all posts from July 2007 that have category 1 assigned.
My problem:
I need to modify the sidebar so it shows links to “this month’s categories” and I have no idea how to do it.
- The topic ‘“this month’s categories”’ is closed to new replies.