Forums

archives: exclude one category from showing in archives (2 posts)

  1. scoopster
    Member
    Posted 11 months ago #

    hello! i've been in one of the post here about this problem., but i can't get it to work., i don't have much knowledge in PHP and stuffs., but if directed properly., i can do it.,

    in my site., i dont want to appear ONE category in the archives... actually., those posts dont constitute the site., but i cant delete them or else i'll lose some links. they are old post anyway...and they are indexed already., i just dont want them to appear in archives...i already made measurements on how to make them inaccessible via homepage., but in archives they can be., so., can you help me exclude them? i dont care if they access them through search., but in archives., i dont.,

    is it okay to lose those links if I just delete the posts? would it affect the site greatly? i estimated it.. for about 150 posts.. :( please help..

  2. doc4
    Member
    Posted 11 months ago #

    scoopster,

    Take a look at the WordPress docs: http://doc4.it/mSB557

    <?php query_posts($query_string . '&cat=-3,-8'); ?>
    <?php if ( have_posts() ) : while ( have_posts() ) : the_post(); ?>

Reply

You must log in to post.

About this Topic