diff options
author | Sem <sembrestels@riseup.net> | 2012-07-11 21:19:14 +0200 |
---|---|---|
committer | Sem <sembrestels@riseup.net> | 2012-07-11 21:19:14 +0200 |
commit | b83574ae1b8ada2bb9c2247492806473df920259 (patch) | |
tree | 30f9010da3cab12bda4921f079cfe86fcef2e7a4 /mod/likes/views | |
parent | 46bd104bd523c08ff2f6bc0342be9ae1251259e8 (diff) | |
parent | 4d42fd0263948eee4a7c7a26ceca0647c01cce32 (diff) | |
download | elgg-b83574ae1b8ada2bb9c2247492806473df920259.tar.gz elgg-b83574ae1b8ada2bb9c2247492806473df920259.tar.bz2 |
Merge tag '1.8.8' of git://github.com/Elgg/Elgg into lorea-preprod
Elgg 1.8.8 release
Conflicts:
js/lib/languages.js
Diffstat (limited to 'mod/likes/views')
-rw-r--r-- | mod/likes/views/default/annotation/likes.php | 4 | ||||
-rw-r--r-- | mod/likes/views/default/likes/button.php | 8 |
2 files changed, 9 insertions, 3 deletions
diff --git a/mod/likes/views/default/annotation/likes.php b/mod/likes/views/default/annotation/likes.php index d41522fc4..abd4df823 100644 --- a/mod/likes/views/default/annotation/likes.php +++ b/mod/likes/views/default/annotation/likes.php @@ -29,9 +29,9 @@ $friendlytime = elgg_view_friendly_time($like->time_created); if ($like->canEdit()) { $delete_button = elgg_view("output/confirmlink",array( - 'href' => "action/likes/delete?annotation_id={$like->id}", + 'href' => "action/likes/delete?id={$like->id}", 'text' => "<span class=\"elgg-icon elgg-icon-delete float-alt\"></span>", - 'confirm' => elgg_echo('deleteconfirm'), + 'confirm' => elgg_echo('likes:delete:confirm'), 'encode_text' => false, )); } diff --git a/mod/likes/views/default/likes/button.php b/mod/likes/views/default/likes/button.php index bc7c8fd8a..956bbcb19 100644 --- a/mod/likes/views/default/likes/button.php +++ b/mod/likes/views/default/likes/button.php @@ -24,7 +24,13 @@ if (elgg_is_logged_in() && $vars['entity']->canAnnotate(0, 'likes')) { ); $likes_button = elgg_view('output/url', $params); } else { - $url = elgg_get_site_url() . "action/likes/delete?guid={$guid}"; + $like = elgg_get_annotations(array( + 'guid' => $guid, + 'annotation_owner_guid' => elgg_get_logged_in_user_guid(), + 'annotation_name' => 'likes', + )); + $like = $like[0]; + $url = elgg_get_site_url() . "action/likes/delete?id={$like->id}"; $params = array( 'href' => $url, 'text' => elgg_view_icon('thumbs-up-alt'), |