Hi,
I'm having problems with my pagination. When in my home page (static page), I click on the Next Page link, it takes me to page 2, but in page 2, there is not Previous Page, and the Next Page points to page 2, again.
Here's what I have around my loop:
<?php $page = (get_query_var('page')) ? get_query_var('page') : 1;
query_posts("post_type=myposttype&paged=$page"); ?>
<?php while (have_posts()) : the_post(); ?>
...My posts here
<?php endwhile; ?>
<?php next_posts_link('Next Page »') ?>
<?php previous_posts_link('« Previous Page') ?>
I have tried adding wp_reset_query(); before and after the loop, but before it breaks it, and after it doesn't seem to make a difference.
I have some more loops in the page (on the sidebar, and one that only shows up in the first page). Could that affect it?
Any ideas?