Support » Themes and Templates » next/previous posts not working

  • I have got my page working. The page displays posts from one category only. Now my problem is that the next page does not display the next page, rather it displays the same six posts that were displayed on the previous page, while the URL reads:

    perhaps I am missing something fundamental. And it is not possible to mix the query post style of PHP I have with the next_post_link tag? If you have any insight on this please help!


        Template Name:  my page template
    <?php get_header(); ?>
    <div class="contentWrapper">
    <div class="push"></div>
    <div class="container">
    <?php if(have_posts()) : ?><?php query_posts('cat=4'); while (have_posts()) : the_post();?>
    				<div class="entry">
    					<?php the_content(); ?>
    				 <p class="postmetadata"><a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>"><?php the_title(); ?> | </a> Posted <?php the_time('F jS, Y') ?> | Category "<?php the_category(', ') ?>" <?php edit_post_link('| Edit','',''); ?> </p>
    	<?php endwhile; ?>
    	<?php else: ?>
    		<div class="post" id="post-<?php the_ID(); ?>">
    			<h2><?php _e('Not Found'); ?></h2z>
    	<?php endif; ?>
    <div class='navigation'>
      <span class='older'><?php next_posts_link('&laquo; Older Entries') ?></span>
      <span class='newer'><?php previous_posts_link('Newer Entries &raquo;') ?></span>
    <!--END  CONTENT!-->	
    <div class="push"></div>
    <?php get_footer(); ?>
Viewing 4 replies - 1 through 4 (of 4 total)
Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘next/previous posts not working’ is closed to new replies.