List popular posts (from WordPress.com Stats plugin) with WP_Query (5 posts)

  1. salromano
    Posted 5 years ago #

    I don't think this would be that hard to accomplish. Though, I'm not necessarily a coder, so I may be wrong. Regardless, here's the request.

    We've got the WordPress.com Stats plugin on our blog to track our visits and post popularity. In conjunction with that, we've got WordPress.com Popular Posts to list the most popular posts WordPress.com Stats are tracking on our front page's right sidebar.

    WordrPress.com Popular Posts' customization possibilities are severely limited, however. I'd like to customize it to match our 'Latest News' bit that shows up on the sidebar whenever you're on an article (example here). We use WP_Query to accomplish that style of listing.

    Is there, perhaps, anybody willing to try this? The code could look something like this (note the "popular=true").

     global $post;
     $myposts = get_posts('numberposts=10&popular=true');
     foreach($myposts as $post) :
  2. salromano
    Posted 5 years ago #

    May I ask why this was moved to 'How-To and Troubleshooting'?

  3. salromano
    Posted 5 years ago #


  4. salromano
    Posted 5 years ago #

    Bump again. I still believe this is in the wrong forum. Why was it moved?

  5. keesiemeijer
    Posted 5 years ago #

    what code do you use to show the 'Latest News'?

Topic Closed

This topic has been closed to new replies.

About this Topic