aboutsummaryrefslogtreecommitdiff
path: root/mod/likes/views/default
diff options
context:
space:
mode:
authorcash <cash@36083f99-b078-4883-b0ff-0f9b5a30f544>2011-04-03 03:46:08 +0000
committercash <cash@36083f99-b078-4883-b0ff-0f9b5a30f544>2011-04-03 03:46:08 +0000
commitba2936c9ec4c0d6015d5794b8bd2d73754a327e1 (patch)
treefc9fd89d54e8620ba83b7a0272d86a33e5f75654 /mod/likes/views/default
parent556bc5c693101b7554c267d3aa003a91856e40b6 (diff)
downloadelgg-ba2936c9ec4c0d6015d5794b8bd2d73754a327e1.tar.gz
elgg-ba2936c9ec4c0d6015d5794b8bd2d73754a327e1.tar.bz2
cleans up likes display which was causing issues in entity menu - less markup
git-svn-id: http://code.elgg.org/elgg/trunk@8924 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'mod/likes/views/default')
-rw-r--r--mod/likes/views/default/likes/display.php14
1 files changed, 7 insertions, 7 deletions
diff --git a/mod/likes/views/default/likes/display.php b/mod/likes/views/default/likes/display.php
index 97a0f89d7..cbfe46078 100644
--- a/mod/likes/views/default/likes/display.php
+++ b/mod/likes/views/default/likes/display.php
@@ -2,8 +2,6 @@
/**
* Elgg likes display
*
- * @package Elgg
- *
* @uses $vars['entity']
*/
@@ -42,17 +40,20 @@ if (elgg_is_logged_in() && $vars['entity']->canAnnotate(0, 'likes')) {
}
}
+echo $likes_button;
+
$list = '';
$num_of_likes = likes_count($vars['entity']);
+
if ($num_of_likes) {
// display the number of likes
if ($num_of_likes == 1) {
- $likes_string = elgg_echo('likes:userlikedthis');
+ $likes_string = elgg_echo('likes:userlikedthis', array($num_of_likes));
} else {
- $likes_string = elgg_echo('likes:userslikedthis');
+ $likes_string = elgg_echo('likes:userslikedthis', array($num_of_likes));
}
$params = array(
- 'text' => "$num_of_likes $likes_string",
+ 'text' => $likes_string,
'title' => elgg_echo('likes:see'),
'rel' => 'popup',
'href' => "#likes-$guid"
@@ -61,6 +62,5 @@ if ($num_of_likes) {
$list .= "<div class='elgg-module elgg-module-popup elgg-likes-list hidden clearfix' id='likes-$guid'>";
$list .= elgg_list_annotations(array('guid' => $guid, 'annotation_name' => 'likes', 'limit' => 99));
$list .= "</div>";
+ echo $list;
}
-
-echo elgg_view_image_block($likes_button, $list); \ No newline at end of file