aboutsummaryrefslogtreecommitdiffstats
path: root/include/conversation.php
diff options
context:
space:
mode:
authorfriendica <info@friendica.com>2012-11-06 00:30:40 -0800
committerfriendica <info@friendica.com>2012-11-06 00:30:40 -0800
commit417d1080d4495ea52469f5292d7bac00f1953eca (patch)
tree1f821443ab1427b6370ce83b9ea15e9061bfe6b5 /include/conversation.php
parent82e74e3520a4208f762be23352ba2e1a0ccb91cf (diff)
downloadvolse-hubzilla-417d1080d4495ea52469f5292d7bac00f1953eca.tar.gz
volse-hubzilla-417d1080d4495ea52469f5292d7bac00f1953eca.tar.bz2
volse-hubzilla-417d1080d4495ea52469f5292d7bac00f1953eca.zip
likes working a bit better - not translateable yet
Diffstat (limited to 'include/conversation.php')
-rw-r--r--include/conversation.php9
1 files changed, 6 insertions, 3 deletions
diff --git a/include/conversation.php b/include/conversation.php
index 532fe0ba1..f763bb0b9 100644
--- a/include/conversation.php
+++ b/include/conversation.php
@@ -89,15 +89,17 @@ function localize_item(&$item){
$item['body'] = item_redir_and_replace_images($extracted['body'], $extracted['images'], $item['contact-id']);
$xmlhead="<"."?xml version='1.0' encoding='UTF-8' ?".">";
+/*
if (activity_match($item['verb'],ACTIVITY_LIKE) || activity_match($item['verb'],ACTIVITY_DISLIKE)){
+// FIXME we shouldn't have a DB lookup on every item
$r = q("SELECT * from `item`,`contact` WHERE
`item`.`contact-id`=`contact`.`id` AND `item`.`uri`='%s';",
dbesc($item['parent_uri']));
if(count($r)==0) return;
$obj=$r[0];
- $author = '[url=' . $item['author-link'] . ']' . $item['author-name'] . '[/url]';
+ $author = '[url=' . $item['author']['xchan_url'] . ']' . $item['author']['xchan_name'] . '[/url]';
$objauthor = '[url=' . $obj['author-link'] . ']' . $obj['author-name'] . '[/url]';
switch($obj['verb']){
@@ -131,6 +133,7 @@ function localize_item(&$item){
$item['body'] = sprintf($bodyverb, $author, $objauthor, $plink);
}
+*/
if (activity_match($item['verb'],ACTIVITY_FRIEND)) {
if ($item['obj_type']=="" || $item['obj_type']!== ACTIVITY_OBJ_PERSON) return;
@@ -1599,7 +1602,7 @@ function like_puller($a,$item,&$arr,$mode) {
$verb = (($mode === 'like') ? ACTIVITY_LIKE : ACTIVITY_DISLIKE);
if((activity_match($item['verb'],$verb)) && ($item['id'] != $item['parent'])) {
- $url = $item['author-link'];
+ $url = $item['author']['xchan_url'];
if((local_user()) && (local_user() == $item['uid']) && ($item['network'] === 'dfrn') && (! $item['self']) && (link_compare($item['author-link'],$item['url']))) {
$url = $a->get_baseurl(true) . '/redir/' . $item['contact-id'];
$sparkle = ' class="sparkle" ';
@@ -1616,7 +1619,7 @@ function like_puller($a,$item,&$arr,$mode) {
$arr[$item['thr_parent']] = 1;
else
$arr[$item['thr_parent']] ++;
- $arr[$item['thr_parent'] . '-l'][] = '<a href="'. $url . '"'. $sparkle .'>' . $item['author-name'] . '</a>';
+ $arr[$item['thr_parent'] . '-l'][] = '<a href="'. $url . '"'. $sparkle .'>' . $item['author']['xchan_name'] . '</a>';
}
return;
}}