From 183e2841c50b9bdd7683680580f2b13eacbfbeca Mon Sep 17 00:00:00 2001 From: cash Date: Sat, 3 Dec 2011 17:26:27 -0500 Subject: basic view counting --- start.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'start.php') diff --git a/start.php b/start.php index f094bd2f4..4942f949a 100644 --- a/start.php +++ b/start.php @@ -285,7 +285,8 @@ function tidypics_entity_menu_setup($hook, $type, $return, $params) { if (elgg_instanceof($entity, 'object', 'image')) { if (elgg_get_plugin_setting('view_count', 'tidypics')) { - $status_text = '27 views'; + $view_info = $entity->getViewInfo(); + $status_text = (int)$view_info['total'] . ' views'; $options = array( 'name' => 'published_status', 'text' => "$status_text", -- cgit v1.2.3