WordPress.org

Ready to get started?Download WordPress

Forums

Smarter Navigation
Category pagination issue (2 posts)

  1. infotamer
    Member
    Posted 1 year ago #

    This issue has been mentioned in 2009:

    Has anyone figured out a workaround when the referrer page is paginated?

    The plugin works great as long as your archive/category/tag referrer pages are not paginated. If the referrer includes cat/page/1, etc., smarter navigation does not allow browsing all single posts in category.

    Thanks

    Miquel
    1 Apr 2009 at 6:24 pm

    What I wanted to achieve is browsing ‘post to post’ (with your pluguin) from the first to the last post in a category, regardless of the pagination. Now you can browse ‘post to post’ until the end of the page you come from (page/1, page/2, etc). I hope this makes sense now…
    Thanks again

    scribu
    2 Apr 2009 at 8:45 am

    Yes, now I get what you’re saying. This is definetly something worth fixing. I’ll see what I can do.

    http://wordpress.org/extend/plugins/smarter-navigation/

  2. versusbassz
    Member
    Plugin Author

    Posted 1 year ago #

    Replace this:
    line 136 of main.php

    $next_posts = self::get_posts( array(
    			'_sn_post' => get_queried_object(),
    			'_sn_op' => $previous ? '<' : '>',
    			'order' => $previous ? 'DESC' : 'ASC',
    			'posts_per_page' => 2,
    		) );

    on this:

    $next_posts = self::get_posts( array(
    			'_sn_post' => get_queried_object(),
    			'_sn_op' => $previous ? '<' : '>',
    			'order' => $previous ? 'DESC' : 'ASC',
    			'posts_per_page' => 2,
    			'paged' => 1
    		) );

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic