Support » Fixing WordPress » Category Specific Template

  • Resolved archaeologyman

    (@archaeologyman)


    I am attempting to create a page template that calls for just one category as opposed to calling all posts.

    Could someone advise on how to do this?

    Thanks.

    I am assuming that I need to add code somewhere in here?:

    <?php
    $temp = $wp_query;
    $wp_query= null;
    $wp_query = new WP_Query();
    $wp_query->query('showposts=5'.'&paged='.$paged);
    if ($wp_query->have_posts()) : while ($wp_query->have_posts()) : $wp_query->the_post();
    global $more; $more = 0;
    ?>
    
    		<h1><a href="<?php the_permalink() ?>" rel="bookmark"><?php the_title(); ?></a></h1>
    		<p><?php the_time('F j, Y'); ?></p>
    
    <?php the_content(); ?>
Viewing 4 replies - 1 through 4 (of 4 total)
Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Category Specific Template’ is closed to new replies.