Forums Forums Search & Filter Pro Pagination not working

Tagged: 

Viewing 10 posts - 11 through 20 (of 21 total)
  • Trevor
    #52760

    I can see an error in the way that the lol-scripts.js is written (the Chrome console reports it as an error), but that is not the cause I think.

    IF you are using the ‘As an archive’ results display method, is the results container set to #main and if so, what happens if you set it to #resource-results ?

    Anonymous
    #52774

    I am using the Custom method of display and the URL is set properly.

    Trevor
    #52777

    Why are you using the Custom method?

    Anonymous
    #52778

    Because it works? I set this up ages ago and I honestly can’t recall the exact reason I chose this method over the others.

    Is there a reason I shouldn’t be using it?

    Trevor
    #52779

    Nice answer 🙂

    AKAIK, it should only be used if recommended to do so by Ross. It isn’t covered in the documentation and it is entirely possible that we would change what it does from one version to another.

    Genesis should work with the normal methods (like As an Archive).

    Anonymous
    #52780

    I know I had problems getting it to work with the other methods. I just don’t recall exactly what those problems were now. We are a couple of days before launch so no way I have time to fiddle with that now. I have to stick with custom.

    Trevor
    #52797

    I cannot see why you would not change it. It does not lose its settings, and with it set to custom, I suspect it may not be fixable.

    Anonymous
    #53903

    It is fixable. I fixed it. For future readers of this thread, this is how I fixed it:

    The issue seems to have been that I didn’t have the correct query name in there. So, in my original code I had:

    <div class="pagination">
    			<div class="nav-previous"><?php next_posts_link( 'Older posts', $query->max_num_pages ); ?></div>
    			<div class="nav-next"><?php previous_posts_link( 'Newer posts' ); ?></div>
    

    Where $query did not represent any active query because it had been renamed as a custom query.

    The correct code is:

    <div class="resources-pagination">
    			<?php previous_posts_link( '<< Previous Page' ); ?>
    	    	<?php next_posts_link( 'Next Page >>', $resources_loop->max_num_pages ); ?>
    		</div>
    

    Where $resources_loop represents the name of the custom query I had in place. (I also removed a couple of unneeded divs and renamed my wrap class.)

    This gives me a functioning Previous and Next pagination.

    What I really want now is to add a better experience for the users with page numbers. I was using paginate_links() with some args and it worked but it was buggy.

    Suggestions?

    Anonymous
    #53906

    Oh and I forgot a key bit of info, that is that the code above had to be repositioned to between the endwhile and endif statements. I previously had the code after the endif.

    Trevor
    #53925

    Did you look at wp-pagenavi? I have not tried it myself.

    Is this thread OK to close?

Viewing 10 posts - 11 through 20 (of 21 total)