WordPress.org

Forums

WP-PostRatings
[resolved] paginate the ranking (4 posts)

  1. BushidoPT
    Member
    Posted 2 years ago #

    Hi Lester great plugin
    I have a question, is it possible to paginate the list.
    I explain, in my website i have almost 10000 posts and in some ranked lists i'm showing more than 100 posts and their respective thumbnails. So, is it possible to show the first 30 posts in one page then in the next page of the same post another 30 and so on? If so, how?
    I'm currently working in my test site but hoping to implement your plugin in the live one. Sorry the English, it's not my main language
    Best regards ;)

    http://wordpress.org/plugins/wp-postratings/

  2. BushidoPT
    Member
    Posted 2 years ago #

    i have tried with the code below but with no luck,
    The correct number of pages appears, but the list is the same in every page

    <ul>
    <?php
    $temp = $wp_query;
    $wp_query= null;
    $wp_query = new WP_Query();
    $wp_query->query('showposts=3'.'&paged='.$paged);
    ?>
    <?php if (function_exists('get_highest_rated')): ?>
        <ul>
            <?php get_highest_rated(); ?>
        </ul>
    
    <?php endif; ?>
    </ul>
  3. Lester Chan
    Member
    Plugin Author

    Posted 2 years ago #

    BushidoPT: you can't paginate that. Use

    <ul>
    <?php
    $temp = $wp_query;
    $wp_query= null;
    $wp_query = new WP_Query();
    $wp_query->query('r_sortby=highest_rated&r_orderby=desc&showposts=3'.'&paged='.$paged);
    ?>
    <?php the_title(); ?> - <?php the_ratings(); ?>
    </ul>
  4. kodiyan
    Member
    Posted 2 years ago #

    Thanks, Resolved my question here.

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic