WordPress.org

Ready to get started?Download WordPress

Forums

WordPress Popular Posts
Getting Most popular list on a blank template (3 posts)

  1. whizzer
    Member
    Posted 3 years ago #

    Hi,

    Basically I am trying to have a list of most popular posts on a blank page so that I can use iframe and embed this on another website.

    What I did was that I created a custom template within my theme which was blank except for the following php code in the body -
    <?php if (function_exists('wpp_get_mostpopular')) wpp_get_mostpopular(); ?>

    I saved this template, then opened up a new 'page' in wordpress and then used this template. Kept the page absolutely blank and thought that this should do it. However this is what I get -
    http://www.therichtimes.com/wordpress/top/

    The sites sidebar (http://www.therichtimes.com/wordpress/) shows the list properly.

    I am sure I am missing something minor , would be mighty obliged if you could point it out. Just immigrated from Movable Type and still finding my feet.

  2. whizzer
    Member
    Posted 3 years ago #

    Add:

    I also tried removing the said code from the template and keeping that absolutely blank while adding [wpp] in the page. It then results in an absolutely blank page, even the 'sorry no data' remarks dont appear.

  3. Héctor Cabrera
    Member
    Plugin Author

    Posted 3 years ago #

    Hi whizzer,

    If you use the wpp_get_mostpopular method with no parameters, it'll use the default values provided by my plugin. That's why you're getting different results.

    Here's an example:

    <?php
    if (function_exists('wpp_get_mostpopular')) wpp_get_mostpopular('range=all&limit=5&stats_comments=0&thumbnail_width=70&thumbnail_height=70');
    ?>

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic