Summary
The WP-PostViews plugin keeps track of how many times a particular article has been viewed and offers a widget and template tag to display post counts.


Use
From Settings > PostViews admins can access a few configuration settings including what users should be counted as views, whether or not bots should be excluded, the wording that will display the information, and to whom the post counts should be displayed.

Upgrade
This plugin has been heavily modified.
In plugins/wp-postviews/ both wp-postviews.php and wp-postviews-widget.php have been altered.
In wp-postviews-widget.php the entire "widget_views_most_viewed" function has been rewritten. This function controls the output of the content to the widget. In order to update, this function will have to replace the same function in the upgraded version. There is a chance that this function in the new version is significantly different. If so, a comparison will have to be made to attempt to consolidate the functionalities of the two. The "widget_views_most_viewed" function runs from line 38 - 137 in the current customized version.

In wp-postviews.php a new function has been created to accompany the existing functions. This should make it easier to update this portion of the plugin because nothing needs to be overwritten, the new function just needs to be added. Below the "get_most_viewed" the added function starts at line 258 and is called "get_most_viewed_this_week". This function runs from line 258 to line 358. It gets all posts from the database and then calculates the most views by week so that the widget will have the data to display the most viewed posts per issue/week. Again, it shouldn't present any problem to add this function to the new version, however there is always a chance that there will be a conflict.

WP-PostViews plugin comes with a widget that has to be activated separately in the plugins interface. However, when upgrading, the two should upgrade together as a package (don't need to retrieve separate files for the widget).
Comments (0)
You don't have permission to comment on this page.