Wordpress widget : Most popular posts
I wanted a “Most popular post” section on my blog, but after some bad experiences with “Popularity Contest” (by Alex King) I decided to write my own. As I already had a statistical mechanism that provided me with the data (namely OWA), it was a no-brainer to write a small plugin that would use the data gathered by OWA. So after a bit of coding, a bit of testing, and polishing… it was done. You can find the script (with some installation help) here. If you have any feedback about it, let me know!

(5 votes, average: 4.60 out of 5)




Hey Karim - very cool plugin. The only piece I would
Peter AdamsHey Karim -
very cool plugin. The only piece I would change would be to use the OWA API for getting the top documents data. That way your plugin won’t break if the OWA schema changes over time (which it will).
Here is some code to get you going:
// OWA must be an active plugin for this to work
global $owa;
// API config values
$owa_params = array();
$owa_params['site_id'] = $owa->config['site_id']; // the current site id
$owa_params['limit'] = '10'; // the number of top pages you want
// API call for Top Pages
$top_pages_data = $owa->api->getMetric('base.topPages', $owa_params);
// Presentation code
foreach ($top_pages_data as $k => $v) {
; // ad your presentation code here
}
Hope that helps. Let me know if you run into any problems.
Whoops. global $owa; should be: global $owa_wp; Thanks.
Peter AdamsWhoops.
global $owa;
should be:
global $owa_wp;
Thanks.
Good suggestion Peter, will try to adjust the script for
Karim VaesGood suggestion Peter, will try to adjust the script for that.
New release : http://www.kvaes.be/wordpress/owa-most-popular-version-02/
Karim VaesNew release :
http://www.kvaes.be/wordpress/owa-most-popular-version-02/
Very cool. There are a few things I was
Mike McLinVery cool. There are a few things I was looking for… Can you make the most popular list time-specific. Like the most popular posts over the past 7 days or whatever? Also, can you show a percentage showing the stories popularity compared to the sites total views that were tallied? I found another plugin that did this, but I couldn’t get it to work [Boakes MostWanted was the plugin, and it used StatTraq for stats].
That's a good suggestion, will see what I can do...
Karim VaesThat’s a good suggestion, will see what I can do…
edit: New version released, with your suggestion.
this is very good web
Shkelqimthis is very good web
It is possible this thigns: I want make an experiment:
UbytovanieIt is possible this thigns: I want make an experiment: What about every month deleting the most popular topic. It is possible to do that in this module?
This is something you could do manually I guess... What
Karim VaesThis is something you could do manually I guess… What would the use of this feature be?
Maybe you also interested in one plugin that wraps the
shuronMaybe you also interested in one plugin that wraps the Popularity contest of Alex King and brings additional “Most Popular” Widget. I call it W-Popularity. It’s full compatible with Popularity contest.
It is possible this thigns: I want make an experiment:
plywoodindonesiaIt is possible this thigns: I want make an experiment: What about every month deleting the most popular topic.
It's possible to do so, but it's not within the
Karim VaesIt’s possible to do so, but it’s not within the scope of this plugin. Check out the api of the OWA framework.
I've created a tutorial implementing the Most Popular posts base
BloggerGeezeI’ve created a tutorial implementing the Most Popular posts base on most commented post, here is the full tutorial for this: Most Popular Post Widget for your Blogger blog (Most Commented Posts)
Hope you find this helpful.
Open Web Analytics » Blog Archive » OWA Most Popular
Trackbacks