Karim Vaes

Why chop at leaves, when one must dig at roots
  • Home
  • About me
    • Curriculum Vitae
    • Services
    • Projects
  • Scripts
    • OWA Most Popular
  • Search
  • License
  • Contact

OWA Most Popular

NOTE : THIS PLUGIN IS OUT-DATED AND WILL NOT WORK IN NEWER VERSIONS OF OWA (1.2+)

Prerequisites

  • OWA Plugin

Changelog

  • 0.1 – inital coding
  • 0.2 – recoded using the API instead of raw SQL queries (suggestion by Peter Adams)
  • 0.3 – added date range parameter (suggestion by Mike McLin)
  • 0.4 – bugfix
  • 0.5 – PostOnly feature
  • 1.0 – Proved stable + Detection if OWA does not have any data yet (bugfix)
  • 1.1 – Code moved to seperate function (for flexibility)
  • 1.2 – New algorithm : Weighted factor = visits / age
  • 1.3 – Options can be set thru the widget control panel
  • 1.4 – Live Feed widget added, can be selected as “algorithm” too
  • 1.4.1 – Bugfix
  • 1.4.2 – Referal layout change
  • 1.5.0 – Wordpress Theme compliance
  • 1.5.1 – Header title fix for Live Feed Widget
  • 1.6.0 – Category algorithm : filter on category id
  • 1.7.0 – Fix for getMetric error on OWA 1.1.1+ installations

Script
Wordpress Extend
Subversion

Installation

  • Get the script from (f.e.) Wordpress Extent
  • Copy the “owa-most-popular-widget.php” file to your to your wp-content/plugins directory (you may put this in a seperate directory within the plugins directory too)
  • Copy the “owa-images” directory to your theme directory
  • Go to the “plugins”-tab under your admin panel
  • Enable the plugin called “OWA Most Popular”

Configuration (widget)

  • Go to the “Presentation”-tab
  • Go to widgets, and drag it/them to your widget sidebar

Configuration (non-widget)

  • OWA Most Popular (api based)
    print owa_api_popular($amount_of_entries,$date_range,$post_only);
    print owa_api_popular();
  • OWA Most Popular (weighted)
    print owa_weighted_popular($amount_of_entries);
    print owa_weighted_popular();
  • Live Traffic Feed
    print owa_live_traffic_feed($amount_of_entries);
    print owa_live_traffic_feed();
  • OWA Most Popular (category)
    print owa_category_popular($category_id,$amount_of_entries,);
    print owa_category_popular($category_id);
  • Defaults:

    $amount_of_entries=10
    $date_range=”last_seven_days”
    $post_only=TRUE

  • Possible values for “date_range”:

    today – last_24_hours – last_hour – last_half_hour – last_seven_days – this_week – this_month – this_year – yesterday – last_week – last_month – last_year – same_day_last_week – same_week_last_year – same_month_last_year – all_time – last_tuesday – last_thrity_days

FAQ

  • Q: “I love your plugin!”
    A: A small thank you as a comment or mail is always appreciated. Donations are also always welcome, in support to help pay the hosting bills. ;-) Or if you want to enrich this blog even more, feel free to check out my wishlist.

  • Q: “Call to a member function getMetric() on a non-object in… ” with OWA Version 1.1.1 (or higher)
    A: The API was suddenly changed in version 1.1.1, so the code needed to be adjusted to handle the new situation. This has been fixed in version 1.7.0 of the plugin.
  • Q: “Call to a member function getMetric() on a non-object in… “
    A: Make sure you have the OWA framework installed.
  • Q: “Is there any way to include every page, instead of only the posts?”
    A: Set the variable “$post_only_owa_popular” to “FALSE”.
  • Q: “I don’t see any output, why is that?”
    A: Does the OWA framework have any data yet? If you just installed the plugin, then the database may still be empty.
  • Q: “Can I change the number of posts it’s displaying?”
    A: For the widget you can do this in the presentation menu, in the raw functions you can do this by passing a number to indicate how many posts you want to display.
  • Q: “How do you determine what is popular?”
    A: The metric “Page Views” is used to determine this.
  • Q: “The plugin doesn’t work; Fix it for me!”
    A: Read the license, it’s provided “as-is”. I’ll do my best effort to reply to all questions, but bare in mind that a message without any debug information is totally useless. I’m not gifted with a certain extra-ordinary talent that empowers me to know all your configurations/implementations. ;-) So if you want help, please provide me with basic debug information.
  • Q: “Could you adjust the plugin to do *insert feature*?”
    A: Feel free to suggest things, but bare in mind that I do this in my spare time. If you want to speed things up, you are also free to contact me for custom services. Yet you are still free to do any changes you like; as it’s released under the BSD-license, you aren’t obliged to contribute your changes back, but it’s always appreciated.
  • Q: “How come I don’t get any flags in my -Live Feed-?”
    A: As stated in the readme.txt file; make sure you copy the owa-images directory to your theme directory.
Share and Enjoy:
  • Digg
  • del.icio.us
  • Facebook
  • Google Bookmarks
  • email
  • Furl
  • Live
  • Ma.gnolia
  • Pownce
  • Reddit
  • Slashdot
  • Technorati
Comments rss
Comments rss
Trackback
Trackback
1 Star2 Stars3 Stars4 Stars5 Stars (No Ratings Yet)
Loading ... Loading ...

81 responses

Ooooh lawd! It must be my birthdya. Thank

Mike McLin

Ooooh lawd! It must be my birthdya. Thank you very much for the update :)

Was my pleasure, I've implemented it myself too. ;)

Karim Vaes

Was my pleasure, I’ve implemented it myself too. ;)

Hi. I love this plugin. Is there any way to

Randy Bryan

Hi. I love this plugin. Is there any way to suppress my default page from showing up in the list of most popular pages? ie, I don’t want randybryan.com to be listed in the list. Thanks!

Perfect!

Mark Evans

Perfect!

*cleaned up comments, as there were a lot of support

Karim Vaes

*cleaned up comments, as there were a lot of support questions here*

I'm getting the following PHP Error Message. Any idea

Anish

I’m getting the following PHP Error Message. Any idea what may be the cause of this

Fatal error: Call to a member function getMetric() on a non-object in /public_html/blog/wp-content/plugins/owa-most-popular/owa-most-popular-widget.php on line 143

Read the FAQ?

Karim Vaes

Read the FAQ?

Could this be altered for links rather than posts?

franz

Could this be altered for links rather than posts?

I don't want to use the widget configuration but the non

Johan

I don’t want to use the widget configuration
but the non widget config.

When I add

in the sidebar I get:
Fatal error: Call to a member function on a non-object in …/owa-most-popular/owa-most-popular-widget.php on line 143

How to fix this?

@Franz: Could you provide me with some details on what

Karim Vaes

@Franz: Could you provide me with some details on what you had in mind?

@Johan: What was the code you used to that caused the above? It would be helpful for me to try to debug this.

my code was:

Johan

my code was:

owa_weighted_popular($amount_of_entries); owa_weighted_popular(); (sorry php block) thanks in advance

Johan

owa_weighted_popular($amount_of_entries);
owa_weighted_popular();

(sorry php block)

thanks in advance

Do you have OWA framework installed? I also made a change

Karim Vaes

Do you have OWA framework installed?

I also made a change in the documentation, the functions return an output, but they do not print it. So you should add “echo” or “print” in front of it.

I currently using Popularity Contest but the alignment is bad: *

Johan

I currently using Popularity Contest but the alignment is bad:
* Virus programma NOD32
veranderd van naam
* Firefox 3 (bèta 1)
* Telenet verhoogt snelheid
* OpenOffice ook bestuurbaar via
de browser
* GPU-Z
* DxAdsl actie Seodsldx
* Belgische Zeitgeist 2007

like to have it too:
* Virus programma NOD32
veranderd van naam
* Firefox 3 (bèta 1)
* Telenet verhoogt snelheid
* OpenOffice ook bestuurbaar via
de browser
* GPU-Z
* DxAdsl actie Seodsldx
* Belgische Zeitgeist 2007

Best Regards, Johan

This plugin relies on OWA (as stated above) for it's

Karim Vaes

This plugin relies on OWA (as stated above) for it’s data. For alignment of data, you may want to try out css? ;-)

I have a strange behavior with my OWA setup. The

Alexander

I have a strange behavior with my OWA setup. The visits are counted successfully if I access the website using Internet Explorer, but no visit is counted if I use Firefox, for the same pages. What can be wrong here? Is there any setting I should look for?

That's probably related to the OWA setup, for support on

Karim Vaes

That’s probably related to the OWA setup, for support on that area, you’re better served with checking at their trac page…

Thanks for taking the time to keep this plugin updated.

planner

Thanks for taking the time to keep this plugin updated. The non-widget support is what I have been waiting for.
Another feature that I would love to see is printing most popular per category or category range. For example:

print owa_api_popular($5); or

print owa_api_popular($5,8);

Where the numbers represent category ids

You get the idea.

Thanks for your time.

Here you go... released ;-)

Karim Vaes

Here you go… released ;-)

Hey, i'm having a bit of trouble on my website.

Daily Yeah

Hey, i’m having a bit of trouble on my website. The regular option doesn’t work and the Live feed option doesn’t display anything. Help :)

Did you just install the plugin, then check out the

Karim Vaes

Did you just install the plugin, then check out the FAQ… ;-) The plugin needs data (read: visitors) to show anything. OWA will not show any trace of what admin users do (if I’m not mistaken).

If that isn’t the problem: Do the other options work? If so, which versions do you use? (owa, owa most popular & wordpress)

Very nice plugin.

plastik

Very nice plugin.

have a strange behavior with my OWA setup. The visits

otogaz

have a strange behavior with my OWA setup. The visits are counted successfully if I access the website using Internet Explorer, but no visit is counted if I use Firefox, for the same pages. What can be wrong here? Is there any setting I should look fo

Could it be that you are logged in (as admin)

Karim Vaes

Could it be that you are logged in (as admin) under your firefox session, and not under internet explorer session? OWA doesn’t count admin visits…

If that shouldn’t solve it for you, then you’re best off to try the mailinglist of OWA.

Hi there, great plugin, I don't think category filter works :-( I

Paul Lacey

Hi there,

great plugin, I don’t think category filter works :-(

I just get the number of my category printed :-(

Any ideas :-)

Cheers

Paul

Just tested it myself, and it works here... How are

Karim Vaes

Just tested it myself, and it works here… How are you invoking it? Did you use the widget form, or thru the php function?

hi Karim, through the template tag (not the widget)... I am doing

Paul Lacey

hi Karim,
through the template tag (not the widget)…

I am doing this: print owa_category_popular(1);

And simply nothing shows…..
This one works: print owa_api_popular();

But I need to only show category 1….

Any ideas are gladly received!

I'm guessing that you do not have a category with

Karim Vaes

I’m guessing that you do not have a category with id 1, or the OWA framework hasn’t registered any visits to posts within this category.

I'm getting the error Fatal error: Call to a member

Andre Kibbe

I’m getting the error Fatal error: Call to a member function on a non-object in /home/akibbe02/public_html/tools-for-thought/wp-content/plugins/owa-most-popular-widget.php on line 173.

This message doesn’t have the “GetMetic()” call, and I have OWA installed and activated. I’m assuming the image folder is supposed to be installed in the folder for my active theme, not in the general “Themes” directory. Any ideas? TIA.

Never mind. I went back to the Plugin Management page,

Andre Kibbe

Never mind. I went back to the Plugin Management page, and it turns out that OWA wasn’t activated.

Thanks for implementing my suggestion. Will come in very handy

planner

Thanks for implementing my suggestion. Will come in very handy for a Linux/BSD site that I’ll be launching in two weeks.

A question. How may this plugin be used with a standalone installation of owa

It doesn't... it expects OWA to be installed in the

Karim Vaes

It doesn’t… it expects OWA to be installed in the same database as where the wordpress tables reside.

Suggest you just sit there and wait till life gets

Fupeneugwen

Suggest you just sit there and wait till life gets easier.

—————————————————————————————————-
http://xanga.com/oscarpierceie

hi there .thanks for plugin: Does anybody know if tis script

baron

hi there .thanks for plugin:

Does anybody know if tis script is compatible with Wordpress 2.5.1 ?

Thanks in advance for any help on this!

regards

It's compatible up to the latest release, as I follow

Karim Vaes

It’s compatible up to the latest release, as I follow the release cycle very closely.

Hi Boss, I found this may redundant "......" Copy the “owa-most-popular-widget.php” file

mpr

Hi Boss,

I found this may redundant “……”

Copy the “owa-most-popular-widget.php” file “to your” to your wp-content/plugins directory (you may put this in a seperate directory within the plugins directory too

I used theme “http://thedeadone.net/” that enable to make forum with wordpress.

I have installed plugin OWA … and found error:

Your help are most appreciated.

thanks

It isn't redundant to some... ;-) So you error is...?

Karim Vaes

It isn’t redundant to some… ;-)
So you error is…?

I meant there are two double word "to your” on

mpr

I meant there are two double word “to your” on your post on the above.

Back to my big problem :)

I used theme “http://thedeadone.net/” that enable to make forum with wordpress. I have installed plugin OWA … and found error:

On widget there are some syntax errors below the widget box :

Fatal error: Call to a member function getMetric() on a non-object in /home1/mampirne/public_html/wp-content/plugins/owa-popular/owa-most-popular-widget.php on line 173

am I should make any change on the OWA code/php or on function.php?

thanks

Do a search on getMetric on THIS page, and you'll

Karim Vaes

Do a search on getMetric on THIS page, and you’ll find the answer to your questions -multiple- times…

You may be expert in writing plugins but you the

Shanker Bakshi

You may be expert in writing plugins but you the biggest DUMBO i have ever seen – The layman guy is asking about his getMetric Problem above and you are idiotically referring him to look in FAQ or to look here and there. You so lazy and Dumbo can’t explain it at one place on your post. Well I will do it for you on my blog after all there are always few guys who extend help

The error regarding the getMetric is handled multiple times on

Karim Vaes

The error regarding the getMetric is handled multiple times on this page, and I get numerous requests (by mail) on this situation. The plugin depends (as clearly stated on this page) on the OWA framework. So if one wishes to use this, they have to install the OWA plugin too…

Let me remind you that I’ve written this code for my own purpose, yet I’ve published this under a FreeBSD license. This way everyone is free to do whatever they want to do with it. I’ve stated that I’d give support on it, depending on the amount of spare time I have.

It’s been downloaded more than 1500 times, yet the amount of “thanks” I’ve got is pretty low in regards to the amount of support I’ve given… So excuse me that I just refer to the FAQ, which is published on the same page as the request(/comment).

Thanks anyway for your comment, I hope this clears things up for you, and might encourage you to think before commenting next time…

Hi, it seems that your plugin (version installed 1.6.0) no

Skumpic

Hi, it seems that your plugin (version installed 1.6.0) no longer works with the last release of OWA (version 1.1.1 released on 31 may).
Can you confirm it and do you think to upgrade your great plugin ??

THANKS in advance
Skumpic

The getMetric issue with the 1.1.1 version has been fixed.

Karim Vaes

The getMetric issue with the 1.1.1 version has been fixed. For some reason the invokation of the API to the OWA framework changed… So to all those who faced the getMetric error on wordpress 2.5+ with OWA 1.1.1+ versions, upgrade to version 1.7.0 (or higher) of this plugin.

Thanks, the new version 1.7.0 works perfectly. Thanks

Skumpic

Thanks, the new version 1.7.0 works perfectly.
Thanks

Good to hear! ;-)

Karim Vaes

Good to hear! ;-)

I have read over this page but didnt notice this

Jesse

I have read over this page but didnt notice this question answered. Using your default call:

print owa_api_popular($amount_of_entries,$date_range,$post_only);

My main posts page shows up as the most viewed. Is there any way to have it not show up?

Thanks, this plugin does solve a LOT of problems for me :)

Try setting the "$post_only" variable to TRUE? Then pages are

Karim Vaes

Try setting the “$post_only” variable to TRUE? Then pages are filtered out of the top content.

Are you sure the images go in the theme directory

Alan Kellogg

Are you sure the images go in the theme directory instead of the images/images directory?

I'm... That's how it always worked for me. But

Karim Vaes

I’m… That’s how it always worked for me. But feel free to experiment… ;-)

Is there anyway to exclude a certain category from being

Jesse

Is there anyway to exclude a certain category from being displayed in the list using the owa_api_popular() tag?

The current version doesn't support this, yet I guess it's

Karim Vaes

The current version doesn’t support this, yet I guess it’s possible to create.

Thanks

Otogaz

Thanks

Very important and useful plugin I think.

burun estetiği

Very important and useful plugin I think.

Could it be that you are logged in (as admin)

kop

Could it be that you are logged in (as admin) under your firefox session, and not under internet explorer session? OWA doesn’t count admin visits…

If that shouldn’t solve it for you, then you’re best off to try the mailinglist of OWA.

Internet Explorer & Firefox are two seperate programs, so they

Karim Vaes

Internet Explorer & Firefox are two seperate programs, so they don’t share their sessions. OWA works on session based and not on IP address. This is because session information is seen as more accurate than IP. Imagine that your are connected thru a router to the internet. All the people surfing on your network would have the same IP, and would would happen then if they would check the same website? ;-)

What about tag pages? I’m finding that alot of my

Plastik cerrahi

What about tag pages? I’m finding that alot of my traffic is coming from tag pages. I didn’t see any settings for true/false with regard to tag pages. Thx.

love this plugin. Is there any way to suppress my

estetik

love this plugin. Is there any way to suppress my default page from showing up in the list of most popular pages? ie, I don’t want randybryan.com to be listed in the list.

So to all those who faced the getMetric error on

ünlüler

So to all those who faced the getMetric error on wordpress 2.5+ with OWA 1.1.1+ versions, upgrade to version 1.7.0 (or higher) of this plugin.

thanks a lot.

dış cephe

thanks a lot.

thanks.

hekimboard

thanks.

Sounds very cool, but I’m not seeing the example you

Burun Estetiği

Sounds very cool, but I’m not seeing the example you talk about.

it’s not all bad news - some things apparently went

Estetik

it’s not all bad news – some things apparently went right with Wordpress 2.3. This isn’t the first scandal to rock Wordpress. It was previously found that

Hi, How do I reduce the font size of the

Matt

Hi,

How do I reduce the font size of the titles used with this plugin?

I noticed the H2 tags being used and changed them the H3 to reduce the size but they don’t seem to change.

Whats happening is that the sidebar where the plugin is being used is too narrow for the default font size for this plugin so its squashing the text between the frames (or in the sidebar)

you can see what happening here: http://www.mattbrownblog.com (by the way – it only squashes the text when using a mac)

Help / advice appreciated.

Thanks
Matt

The code is currently not foreseen, as it deviated from

Karim Vaes

The code is currently not foreseen, as it deviated from the default behaviour of wordpress plugins. It’s possible to adapt the script to encorporate such a feature.

nice post!

tercüme

nice post!

thanks

ikinci el iş makinaları

thanks

new version works great...

temel kimya

new version works great…

great page! thanks a lot.

lazer epilasyon

great page! thanks a lot.

nice post!

iddaa

nice post!

Hi Karim, very good little plugin, simple to use anywhere

Yorik

Hi Karim, very good little plugin, simple to use anywhere in your blog… Thanks a lot for making it! Cheers Yorik

Question about WordPress Plugin - Popular Posts - Personal Development

Trackbacks
  • Question about WordPress Plugin – Popular Posts – Personal Development for Smart People Forums
  • A Quick Update | Saphrym
  • Установка статистики OWA на Wordpress
  • 什么叫什么,搜搜就知道 » Blog Archive » OWA Most Popular
  • WordPress popular posts plugins & widgets | CleverSage
  • Open Web Analytics. Статистики блога или “что читают посетители вашего блога”.. Press WordPress – плагины WordPress, WordPress темы, блог WordPress, Вордпресс
  • Leonaut.com
  • Темы для WordPress, DLE. » Blog Archive » Open Web Analytics – Полная статистика блога.
  • 4webmasters » Top 1000 WordPress Plugin Authors
  • En.nicuilie.eu Blogs » Top 1000 WordPress Plugin Authors
  • The eight best WordPress plugins for your blog | CompleteFusion

Leave a comment

You can use these tags : <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

Recent Posts

  • Why IT shouldn’t be run as a business…
  • Sushi Etiquette
  • Wage cut or wage freeze?
  • Basic business money making concepts
  • Quote of the day

Similar Posts

  • OWA Most Popular – version 1.2
  • OWA Most Popular – Version 1.6.0
  • OWA Most Popular – version 0.3
  • Wrapperscript around ghettoVCB
  • Scripts

Recent Comments

  • Jahm Mitt on Disabling the openoffice splash screen in ubuntu
  • Desactivar Splash Screen de Openoffice.org « Gnometips on Disabling the openoffice splash screen in ubuntu
  • NiTRo on Using ssh keys with ESXi
  • sscdvp on solaris & md5 checksum
  • Lydia Hirt on Dan Pink on the surprising science of motivation

Commercial

Categories

2.0 Ads Agile Bash Blogroll Book Brain Business Career Change CIO Collaboration Communication Corner Creative CRM Culture Desktop Development Dreambox Drupal Education Entrepreneur F5 Firefox Food Freelance Fun General Green Growth High Availability Human Resources Idea Infrastructure Insightful Interesting IT Java Lesson License Life Malware Management Mind Model MythTV Network NLP OpenSource Performance PHP PM Presentation Project Quote Remote Scrum Security SEO Social Spam Storage Stress Tactical Team Tech TED Time Management Tip Tool TV Ubuntu Unix/Linux Vids Vim Virtual VmWare Voip Web Wordpress

Archives

  • January 2010
  • December 2009
  • November 2009
  • October 2009
  • August 2009
  • July 2009
  • June 2009
  • April 2009
  • March 2009
  • February 2009
  • January 2009
  • December 2008
  • November 2008
  • October 2008
  • September 2008
  • August 2008
  • July 2008
  • June 2008
  • May 2008
  • April 2008
  • March 2008
  • February 2008
  • January 2008
  • December 2007
  • November 2007
  • October 2007
  • September 2007
  • August 2007
  • July 2007
  • June 2007
  • May 2007
  • April 2007
rss Comments rss valid xhtml 1.1 design by jide licensed as Creative Commons Attribution