• Hi,

    I’ve created my own theme, and running 3.5.2, I’m trying to organize my Archived posts by category and by month. Using various plugins, I’m able to see the organization, but choosing any particular month returns all posts.

    I’ve tried a number of plugins that feature category/monthly/yearly organization – all work as advertised, but do not separate out the posts when a given month is selected.

    Here is the URL in question:

    http://meta.uoregon.edu/?page_id=36

    Here’s what I’m using in my archive.php template:

    <?php
    $paged = (get_query_var(‘paged’)) ? get_query_var(‘paged’) : 1;
    query_posts(‘category_name=News&paged=’ . $paged); ?>

    <?php while ( have_posts() ) : the_post();?>
    <div class=”newspost”>
    <h2>” rel=”bookmark” title=”Permanent Link to <?php the_title_attribute(); ?>”><?php the_title(); ?></h2>
    <?php the_content();?>
    <h4> <?php echo get_the_date(); ?></h4>
    </div><!–newspost–>

    <?php endwhile;?>

    Using query_posts works for selecting the individual category – i’m not worried (yet) about the pagination . I suspect I’m missing something in this code that will allow the return of a single month, but haven’t found a solution yet.

    Any and all help is appreciated.

  • The topic ‘Archives by category and by month’ is closed to new replies.