aboutsummaryrefslogtreecommitdiffstats
path: root/mod
diff options
context:
space:
mode:
authorduthied <duthied@gmail.com>2011-10-08 20:52:31 -0700
committerduthied <duthied@gmail.com>2011-10-08 20:52:31 -0700
commit096347040491081164857f51e13852b3e05983d7 (patch)
tree4fbc49c3fc8be31fe5089a9cf06a896aa2bdf2cc /mod
parent91bc2fc9b6a38724955c8c035e5f228df6dddd62 (diff)
parent8eedbf30f1da18c7eae8d822293faf8056545e65 (diff)
downloadvolse-hubzilla-096347040491081164857f51e13852b3e05983d7.tar.gz
volse-hubzilla-096347040491081164857f51e13852b3e05983d7.tar.bz2
volse-hubzilla-096347040491081164857f51e13852b3e05983d7.zip
Merge pull request #23 from duthied/master
+posts to the notifications page
Diffstat (limited to 'mod')
-rw-r--r--mod/notifications.php15
1 files changed, 12 insertions, 3 deletions
diff --git a/mod/notifications.php b/mod/notifications.php
index d4cb4101b..083476501 100644
--- a/mod/notifications.php
+++ b/mod/notifications.php
@@ -191,6 +191,7 @@ function notifications_content(&$a) {
$tpl_item_dislikes = get_markup_template('notifications_dislikes_item.tpl');
$tpl_item_friends = get_markup_template('notifications_friends_item.tpl');
$tpl_item_comments = get_markup_template('notifications_comments_item.tpl');
+ $tpl_item_posts = get_markup_template('notifications_posts_item.tpl');
$notif_content = '';
@@ -205,8 +206,8 @@ function notifications_content(&$a) {
'$item_text' => sprintf( t("%s liked %s's post"), $it['author-name'], $it['pname']),
'$item_when' => relative_date($it['created'])
));
-
break;
+
case ACTIVITY_DISLIKE:
$notif_content .= replace_macros($tpl_item_dislikes,array(
'$item_link' => $a->get_baseurl().'/display/'.$a->user['nickname']."/".$it['parent'],
@@ -214,8 +215,8 @@ function notifications_content(&$a) {
'$item_text' => sprintf( t("%s liked %s's post"), $it['author-name'], $it['pname']),
'$item_when' => relative_date($it['created'])
));
-
break;
+
case ACTIVITY_FRIEND:
$xmlhead="<"."?xml version='1.0' encoding='UTF-8' ?".">";
@@ -228,8 +229,16 @@ function notifications_content(&$a) {
'$item_text' => sprintf( t("%s is now friend with %s"), $it['author-name'], $it['fname']),
'$item_when' => relative_date($it['created'])
));
-
break;
+
+ case ACTIVITY_POST;$notif_content .= replace_macros($tpl_item_posts,array(
+ '$item_link' => $a->get_baseurl().'/display/'.$a->user['nickname']."/".$it['parent'],
+ '$item_image' => $it['author-avatar'],
+ '$item_text' => sprintf( t("%s posted"), $it['author-name']),
+ '$item_when' => relative_date($it['created'])
+ ));
+ break;
+
default:
$notif_content .= replace_macros($tpl_item_comments,array(
'$item_link' => $a->get_baseurl().'/display/'.$a->user['nickname']."/".$it['parent'],