Support » Plugins » WordPress pagination showing same posts on every page with ajax.

  • I have a page that that is run on ajax. When the user selects to see older posts jquery calls the load() function and loads the next set of posts in a specified section.

    my jquery:

    jQuery('.moreButton a, .backButton a').live('click', function(e){
            var link = jQuery(this).attr('href');
            jQuery('.blogDisplay').fadeOut(200).load(link + ' .blogDisplay', function(){ jQuery('.blogDisplay').fadeIn(800); makeThumb();});

    the section I have in the index:

    if (have_posts()):?>
    <?php while (have_posts()) : the_post(); ?>

    when the page loads first it shows the correct set of posts. when I choose to see the next set it always shows the same first set. However, when I remove the change in query_posts() to show all the posts it woks perfectly.

    Any ideas?

  • The topic ‘WordPress pagination showing same posts on every page with ajax.’ is closed to new replies.