• I’ve seen these features in other WP blogs but I’m not sure which hacks/plugins they used. Any ideas? Thanks!

Viewing 9 replies - 1 through 9 (of 9 total)
  • there is a difference between most frequently commented upon (lists of which are created with plugins mentioned in the links above) and most often read.
    Is there a plugin that will keep track of which posts are most frequently read?

    If you’re using StatTraq, then the MostWanted plugin does part of what your after (lists the most popular posts). It uses StatTraq usage tables in order to work out post popularity.

    This is the error I got following the directions.
    Warning: Invalid argument supplied for foreach() in …my-hacks.php on line 18

    Ok, I give. What resides on line 18 in your my-hacks.php?

    function show_pop_posts() {
    global $wpdb, $siteurl, $tableposts;
    $results = $wpdb->get_results("select postnumber, cntaccess from mostAccessed ORDER BY cntaccess DESC LIMIT 10");
    foreach ($results as $result) {
    $postnumber = $result->postnumber;
    $post = @$wpdb->get_row("SELECT ID, post_title FROM $tableposts WHERE '$postnumber' = ID");
    //$post_title = substr($post->post_title, 0, 20);
    $post_title = $post->post_title;
    //$url = get_permalink($post->ID);
    echo "

    I am beginning to suspect that its a problem with foreach() because I have tried a couple of similar plugins (not hacks), and they always give me an error whenever foreach() is encountered.
    Where can I go to learn about this stuff?
    Kafkaesqui, thanks for “give”ing ??

    alright. problem solved.
    I would like to recomend to anyone who is looking to list “most popular entries” etc. — you should use Wp-Dstats.
    The directions were a tiny bit difficult for a novice user to comprehend, but the learning curve wasn’t too steep, and the best part was, no errors!
    Maybe in a few days or so I will do a write up and maybe do something to make the docs a bit more idiot-proof. I am happy with this plugin.

Viewing 9 replies - 1 through 9 (of 9 total)
  • The topic ‘Most Popular Post & Recent Comments’ is closed to new replies.