From 05a70a8760d705e80c548d96a9d083ab032dbd8b Mon Sep 17 00:00:00 2001 From: friendica Date: Wed, 5 Feb 2014 19:16:12 -0800 Subject: add chatroom links --- include/conversation.php | 14 ++++++++++++++ 1 file changed, 14 insertions(+) (limited to 'include') diff --git a/include/conversation.php b/include/conversation.php index 633435871..77c7bac70 100644 --- a/include/conversation.php +++ b/include/conversation.php @@ -1488,6 +1488,19 @@ function profile_tabs($a, $is_owner=False, $nickname=Null){ 'id' => 'files-tab', ); } + + require_once('include/chat.php'); + $chats = chatroom_list($a->profile['profile_uid']); + + $tabs[] = array( + 'label' => t('Chatrooms') . '(' . count($chats) . ')', + 'url' => $a->get_baseurl() . '/chat/' . $nickname, + 'sel' => ((argv(0) == 'chat') ? 'active' : ''), + 'title' => t('Chatrooms'), + 'id' => 'chat-tab', + ); + + if($is_owner) { $tabs[] = array( 'label' => t('Events'), @@ -1506,6 +1519,7 @@ function profile_tabs($a, $is_owner=False, $nickname=Null){ ); } + if($is_owner && feature_enabled($a->profile['profile_uid'],'webpages')) { $tabs[] = array( 'label' => t('Webpages'), -- cgit v1.2.3