]> gitweb.fluxo.info Git - lorea/elgg.git/commitdiff
bookmark stats now correct, missing strings applied and a function call moved out...
authordave <dave@36083f99-b078-4883-b0ff-0f9b5a30f544>
Fri, 2 Apr 2010 08:26:53 +0000 (08:26 +0000)
committerdave <dave@36083f99-b078-4883-b0ff-0f9b5a30f544>
Fri, 2 Apr 2010 08:26:53 +0000 (08:26 +0000)
git-svn-id: http://code.elgg.org/elgg/trunk@5574 36083f99-b078-4883-b0ff-0f9b5a30f544

mod/bookmarks/all.php
mod/bookmarks/languages/en.php
mod/bookmarks/views/default/bookmarks/stats.php

index 88258c85572837b933837c3dce6750493352124f..a4bdae7af54d9e27c0dfe4bed082873f07bb613c 100644 (file)
@@ -28,7 +28,8 @@ if(isloggedin()){
        $area3 .= elgg_view("bookmarks/bookmarklet");   
 }      
 // include statistics
-$area3 .= elgg_view("bookmarks/stats");
+$count = elgg_get_entities(array('type' => 'object', 'subtype' => 'bookmarks', 'count' => true));
+$area3 .= elgg_view("bookmarks/stats", array('count' => $count));
 // Format page
 $body = elgg_view_layout('one_column_with_sidebar', $area1.$area2, $area3);
                
index 2ba00a8ddd571e05d034c0a7e63b4f29b8897b2d..1af2e613f9080278b35dc3e30fb80637621d93fb 100644 (file)
@@ -34,7 +34,8 @@ $english = array(
                'bookmarks:shared' => "Bookmarked",
                'bookmarks:visit' => "Visit resource",
                'bookmarks:recent' => "Recent bookmarks",
-
+               'bookmarks:stats' => "Bookmark stats",
+               'bookmarks:resources' => "resources bookmarked",
                'bookmarks:river:created' => '%s bookmarked',
                'bookmarks:river:annotate' => 'posted a comment on this bookmarked item',
                'bookmarks:river:item' => 'an item',
index a9cad12b3a804b6837f9fdb8cdb06cec86b739bd..77c3d703f44197119ae1b31305d76f2e7e1b60c6 100755 (executable)
@@ -3,8 +3,5 @@
  * All site bookmark stats
  **/
  
-$count_bookmarks = elgg_get_entities("object", "bookmarks",0,"",10,0,true,0,null,0,0);
-$count_bookmark_comments = count_annotations(0, "object", "bookmarks","generic_comment");
-
-echo "<h3>Bookmark stats</h3>";
-echo "<p>".$count_bookmarks . " resources bookmarked.</p>";
+echo "<h3>".elgg_echo('bookmarks:stats')."</h3>";
+echo "<p>". $vars['count'] . " " . elgg_echo('bookmarks:resources') .".</p>";
\ No newline at end of file