Views counter v1.9.3

Release Notes

(version 1.9.3)

  • Bug correction: The functions list_entities_by_most_viewed() and get_entities_by_most_viewed() were corrected. There was a bug: Only the views of 1 user was beeing considered before.
  • Bug correction: The functions list_entities_by_most_viewed() and get_entities_by_most_viewed() were renamed to list_entities_by_views_counter() and get_entities_by_views_counter()
  • Bug correction: The hooks list_entities_by_most_viewed_hook() and get_entities_by_most_viewed_hook() were renamed to list_entities_by_views_counter_hook() and get_entities_by_views_counter_hook()
  • New function: get_last_view_time() and its hook get_last_view_time_hook() created
  • New function: update_last_view_time() and its hook update_last_view_time_hook() created
  • New function: did_see_last_update() and its hook did_see_last_update_hook() created

(version 1.6.0)

  • Plugin setting for display or no display the views counter

(version 1.5.0)

  •  A new function that will be very useful for developers: list_entities_by_most_viewed($options)). Allows to retrieve a list of entities ordered by number of views
  • Some new functions registered for get hooks from another plugins that wants to use the views counting system but in a neutral way, just triggering elgg hooks.
  • Basic CSS customization through plugin settings
  • Now It is possible to include the views counter number via Javascript, just setting the container input ID on plugin settings

(version 1.1.0)

  • A common view name for include the views counter system by another views counter plugins just using: elgg_views('views_counter',array('entity'=>ENTITY))

(version 1.0.0)

  • A view system for any elgg entity that may be used easily through the function add_views_counter(ENTITY_GUID)
  • A view that may be used for add a views counter to any elgg entity
  • System that allow the admin add automatically a views counter to: users, groups, grouptopics and all subtypes of object that follow the patterns of the elgg_view_entity() function
  • A function for retrieve the views counter for any elgg entity easily: get_views_counter(ENTITY_GUID)
  • A elgg view that displays the views counter for any elgg entity: "views_counter/display_views_counter"
  • A admin page where the admin can see the views for the entities
  • A demo of how to use the views_counter plugin that makes more easy to use It and makes sure if It is working or not
  • The link 'views counter demo' shows me a white side????



  • Thanks for this Desiron.

    We have a concern that it is somewhat of a privacy invasion to see exactly who has viewed a partciular object. But we like the anonymous counter feature. Is it possible to NOT have the names of those who have viewed the view, made accessible to the creator?

    Thanks again and great work?


  • I really like this plugin - wonderful documentation, elegant code, useful functionality.

    Referencing Terry's question of 43 days ago it looks like it won't show the names of viewers to non-admins. One small bug though: if a user is not admin and the counter is displayed, it still shows a link to the admin-only page showing who viewed the entity - which rightly gives an error. Changing the condition for the if..then on line 23 of display_views_counter.php to isadminloggedin() seems to do the trick.

    Thanks again.


  • Do you really want the counter to increment if you, yourself viewed your OWN page??

  • Is this counter compatible with elgg 1.8?

  • will there be an updated version? doesn't work in 1.83


I have been developing plugins and extensions for elgg since 2009 February. Currently I am acting in some plugins development, fixing/upgrading some elgg plugins that are not being continued and modifying or extending the Elgg Framework itself.


  • Category: Site admin
  • License: GNU General Public License (GPL) version 2
  • Updated: 2014-11-17
  • Downloads: 2425
  • Recommendations: 4

Other Projects

View Desiron's plugins