WordPress.org

Ready to get started?Download WordPress

Forums

Categoy exclusion? (4 posts)

  1. Freakstylez
    Member
    Posted 7 years ago #

    Are there any existing plug-ins that allow you to filter categories? For example, I'd like to add a category about gaming to my blog, but intended audience does not consist entirely of gamers. Is there a plug-in that allows the user to deselect a category and view only the categories they choose to view?

    I suppose that, if worse comes to worse, I can maintain two blogs, or simply maintain a personal blog and keep the gaming information to a separate information medium, such as a CMS.

  2. anabelle
    Member
    Posted 7 years ago #

    find

    ´<?php if (have_posts()) : while (have_posts()) : the_post(); ?>´

    in the index.php file of the theme youre using

    add below

    <?php if ( !(in_category('4')) || !is_home() ) { ?>
    <!-- Output the post here -->
    <?php }>

    replace 4 with the id of the category you want excluded.

    take a look at this http://wordpress.org/support/topic/74890?replies=9

  3. davidsugalski
    Member
    Posted 7 years ago #

    ok. so, then will this also exlude the music posts from the blog posts? they need to be 2 completely seperate blogs. thanks for the help.

  4. davidsugalski
    Member
    Posted 7 years ago #

    doesn't work. getting a parse error after copying directly. don't know what that means.

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags