WordPress Popular Posts
-
I’ve been looking for a while to find a wordpress plugin which can display the most popular plugins in a certain category, this seems to have the capability although my theme uses hub categories rather than regular categories for pages.
I found a post the developer made about how to show up the most popular in certain categories by using this code:
<?php if ( function_exists('wpp_get_mostpopular') ) { // We're viewing the category archive, get top posts under this category if ( is_category() ) { $catID = get_query_var('cat'); wpp_get_mostpopular( "range=all&stats_views=1&order_by=views&cat=" . $catID ); } // We're viewing some other page, don't use the category filter else { wpp_get_mostpopular( "range=all&stats_views=1&order_by=views" ); } } ?>
Is this any way I can manipulate this code to use it on hub categories rather than regular ones?
Much appreciated!
- The topic ‘WordPress Popular Posts’ is closed to new replies.