diff options
author | zotlabs <mike@macgirvin.com> | 2017-03-15 21:26:28 -0700 |
---|---|---|
committer | zotlabs <mike@macgirvin.com> | 2017-03-15 21:26:28 -0700 |
commit | f6b643e84ee1ce8b4e13f959e0d58804f4aabd3b (patch) | |
tree | c22cc6aee9776ef34940ab539c6fb7f7e80e45ec /Zotlabs/Widget/Chatroom_list.php | |
parent | 16d750d1f6cf0d2866388269e02445630c4e3464 (diff) | |
download | volse-hubzilla-f6b643e84ee1ce8b4e13f959e0d58804f4aabd3b.tar.gz volse-hubzilla-f6b643e84ee1ce8b4e13f959e0d58804f4aabd3b.tar.bz2 volse-hubzilla-f6b643e84ee1ce8b4e13f959e0d58804f4aabd3b.zip |
widgets cont.
Diffstat (limited to 'Zotlabs/Widget/Chatroom_list.php')
-rw-r--r-- | Zotlabs/Widget/Chatroom_list.php | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/Zotlabs/Widget/Chatroom_list.php b/Zotlabs/Widget/Chatroom_list.php new file mode 100644 index 000000000..e2aad0e05 --- /dev/null +++ b/Zotlabs/Widget/Chatroom_list.php @@ -0,0 +1,24 @@ +<?php + +namespace Zotlabs\Widget; + +class Chatroom_list { + + function widget($arr) { + + if(! \App::$profile) + return ''; + + $r = \Zotlabs\Lib\Chatroom::roomlist(\App::$profile['profile_uid']); + + if($r) { + return replace_macros(get_markup_template('chatroomlist.tpl'), array( + '$header' => t('Chatrooms'), + '$baseurl' => z_root(), + '$nickname' => \App::$profile['channel_address'], + '$items' => $r, + '$overview' => t('Overview') + )); + } + } +} |