ThemeShaper Forums » Thematic


Creating special archive page that excludes just one category

(3 posts)
  • Started 11 years ago by semisara
  • Latest reply from helgatheviking
  • This topic is not resolved
  1. First of all I'm going to apologise for asking what is probably a stupid question. I've created Wordpress themes before, but since the age of Thematic I've begun to leave it to the pros and now I'm lost when trying to tweak.

    My website ( is composed of two types of posts: picture-only posts that are all tagged in the category "one shot" (category ID 8), and picture and text posts that are placed into a variety of categories. I'd like to create a single page that uses the archive template to display all posts EXCEPT ones in category 8, making it easier for readers to find text posts.

    I'm *assuming* I should be working with either the archives.php "Archive" code, or the archive.php "Archives Page Page Template" code. Unfortunately I'm not sure which one I should copy into a new template php file, and I'm not sure how to edit the code to exclude only category 8.

    Can anyone point me in the correct direction?

    Posted 11 years ago #
  2. Bumping this.. any links to relevant information or advice?

    Posted 11 years ago #
  3. the archives template currently shows posts by category and by date. but to modify this particular template, you could override the thematic_category_archives() function like so:

    function childtheme_override_category_archives() { ?>
    						<li id="category-archives" class="content-column">
    							<h2><?php _e('Archives by Category', 'thematic') ?></h2>
    								<?php wp_list_categories('optioncount=1&feed=RSS&title_li=&show_count=1&exclude=8') ?>
    		<?php }

    but if that's not what you want, then you could create your own template to do whatever you wanted. there are probably several decent plugins that do better archives than the thematic or WP defaults. also, image only posts could now be of the image, "post format". thematic doesn't have them by default yet, but they're easy enough to add and make a lot more sense than being in a specific category.

    Posted 11 years ago #

RSS feed for this topic

Topic Closed

This topic has been closed to new replies.