previous_posts_link next_posts_link problem
-
<?php get_header(); ?> <div class="maincontent"> <div class="contentleft"> <?php if (have_posts()) : ?> <?php query_posts('posts_per_page=3'); $do_not_duplicate = array(); while (have_posts()) : the_post(); $do_not_duplicate[] = $post->ID; ?> <div class="post"> <div class="posttitle"><h1><a href="<?php the_permalink() ?>" title="<?php the_title(); ?>"><?php the_title(); ?></a></h1></div> <div class="datebox"><p><span><?php the_time('F j, Y') ?></span> | <?php comments_popup_link('No Comments', '1 Comments', '% Comments'); ?></p></div> <div class="postcontent"> <?php the_content('Read the rest of this entry »'); ?> <iframe src="https://www.facebook.com/plugins/like.php?href=<?php echo urlencode(get_permalink($post->ID)); ?>&layout=standard&show-faces=true&width=500&action=like&colorscheme=light" scrolling="no" frameborder="0" allowTransparency="true" style="border:none; overflow:hidden; width:500px; height:60px"></iframe> <div class="commentslink"><p><?php comments_popup_link('No Comments', '1 Comments', '% Comments'); ?> | <a href="<?php the_permalink() ?>">Leave a comment</a></p></div> <div class="tagbox"> <p>Tagged As | <?php the_tags(__(''), ', ', ''); ?></p> </div> </div> </div> <?php endwhile; ?> <?php else : ?> <h2 class="center">Not Found</h2> <p class="center">Sorry, but you are looking for something that isn't here.</p> <?php endif; ?> <div id="bottomposts"> <?php if (have_posts()) : ?> <?php rewind_posts(); ?> <?php query_posts('posts_per_page=11'); while (have_posts()) : the_post(); update_post_caches($posts); if ( !in_array( $post->ID, $do_not_duplicate ) ): ?> <div class="postovi"> <h2><a href="<?php the_permalink(); ?>" id="post-<?php the_ID(); ?>"><?php the_title(); ?></a></h2> <?php echo excerpt(55); ?><p></p> <a href="<?php the_permalink(); ?>" id="post-<?php the_ID(); ?>">Read more...</a> </div> <?php endif; ?> <?php endwhile; ?> <?php else : ?> <h2 class="center">Not Found</h2> <p class="center">Sorry, but you are looking for something that isn't here.</p> <?php endif; ?> </div> <div class="pagination"> <div class="previous"><?php previous_posts_link('Previous Entries') ?></div> <div class="next"><?php next_posts_link('Next Entries') ?></div> </div> </div> <div class="contentright"> <?php get_sidebar(); ?> </div> </div> <?php get_footer(); ?>
I am having problem with navigation, i use 2 loops in 1st i display 3 recent posts , and in the next one i display 8 short text posts
but my page navigation doesnt work, allways showing same posts
- The topic ‘previous_posts_link next_posts_link problem’ is closed to new replies.