Browse Source
- Remove a lot of old code
- Remove a lot of old code
- Fix some CSS - Fix the post links + pictures in the UI - Add some filters in the events - Change some UI strings - Reimplement properly the comments (read-only)pull/16/head
100 changed files with 334 additions and 2051 deletions
-
8app/assets/js/movim_tpl.js
-
5app/controllers/AboutController.php
-
3app/controllers/AccountController.php
-
3app/controllers/AccountnextController.php
-
3app/controllers/AdminController.php
-
4app/controllers/AdminloginController.php
-
7app/controllers/BlogController.php
-
18app/controllers/DiscoverController.php
-
21app/controllers/ExploreController.php
-
11app/controllers/FeedController.php
-
32app/controllers/FriendController.php
-
5app/controllers/LoginController.php
-
8app/controllers/MediaController.php
-
23app/controllers/NodeController.php
-
23app/controllers/NodeconfigController.php
-
2app/controllers/NotfoundController.php
-
4app/controllers/PodsController.php
-
19app/controllers/ProfileController.php
-
23app/controllers/ServerController.php
-
4app/models/postn/PostnDAO.php
-
12app/views/discover.tpl
-
24app/views/explore.tpl
-
1app/views/feed.tpl
-
21app/views/node.tpl
-
28app/views/nodeconfig.tpl
-
2app/views/page.tpl
-
27app/views/profile.tpl
-
25app/views/server.tpl
-
75app/widgets/Chat/Chat.php
-
13app/widgets/Chat/_chat_config_room.tpl
-
3app/widgets/Chat/_chat_header_room.tpl
-
4app/widgets/Chat/locales.ini
-
2app/widgets/Chats/_chats_item.tpl
-
37app/widgets/Contact/Contact.php
-
12app/widgets/Contact/_contact_header.tpl
-
15app/widgets/Discover/Discover.php
-
25app/widgets/Discover/discover.tpl
-
1app/widgets/Discover/locales.ini
-
52app/widgets/Explore/Explore.php
-
9app/widgets/Explore/_explore_chatrooms.tpl
-
9app/widgets/Explore/_explore_groups.tpl
-
36app/widgets/Explore/explore.tpl
-
5app/widgets/Explore/locales.ini
-
149app/widgets/Feed/Feed.php
-
4app/widgets/Feed/_feed_empty.tpl
-
3app/widgets/Feed/feed.css
-
31app/widgets/Feed/feed.tpl
-
4app/widgets/Feed/locales.ini
-
7app/widgets/Group/Group.php
-
4app/widgets/Group/_group_header.tpl
-
2app/widgets/Group/_group_posts.tpl
-
3app/widgets/Group/locales.ini
-
20app/widgets/Hot/Hot.php
-
25app/widgets/Hot/hot.tpl
-
1app/widgets/Hot/locales.ini
-
2app/widgets/Menu/Menu.php
-
2app/widgets/Menu/_menu_list.tpl
-
274app/widgets/Node/Node.php
-
105app/widgets/Node/_node_content.tpl
-
4app/widgets/Node/_node_empty.tpl
-
14app/widgets/Node/_node_metadata.tpl
-
7app/widgets/Node/locales.ini
-
34app/widgets/Node/node.tpl
-
121app/widgets/NodeConfig/NodeConfig.php
-
5app/widgets/NodeConfig/locales.ini
-
29app/widgets/NodeConfig/nodeconfig.tpl
-
2app/widgets/Notifs/_notifs_from.tpl
-
11app/widgets/Pods/pods.tpl
-
51app/widgets/Post/Post.php
-
28app/widgets/Post/_post.tpl
-
23app/widgets/Post/_post_comments.tpl
-
6app/widgets/Post/_post_header_create.tpl
-
2app/widgets/Post/locales.ini
-
53app/widgets/Profile/Profile.php
-
22app/widgets/Profile/_profile_vcard.tpl
-
2app/widgets/Profile/locales.ini
-
41app/widgets/Profile/profile.css
-
13app/widgets/Profile/profile.js
-
4app/widgets/Profile/profile.tpl
-
32app/widgets/Rooms/Rooms.php
-
5app/widgets/Rooms/_rooms_list.tpl
-
4app/widgets/Roster/Roster.php
-
1app/widgets/Roster/roster.js
-
5app/widgets/Roster/roster.tpl
-
165app/widgets/ServerNodes/ServerNodes.php
-
4app/widgets/ServerNodes/locales.ini
-
24app/widgets/ServerNodes/servernodes.tpl
-
118app/widgets/Wall/Wall.php
-
40app/widgets/Wall/_wall_head.tpl
-
2app/widgets/Wall/locales.ini
-
10app/widgets/Wall/wall.js
-
17app/widgets/Wall/wall.tpl
-
54lib/XMPPtoForm.php
-
6linker.php
-
2locales/locales.ini
-
31system/Route.php
-
1system/controllers/BaseController.php
-
65system/template/TplPageBuilder.php
-
5themes/material/css/article.css
-
22themes/material/css/style.css
@ -1,18 +0,0 @@ |
|||
<?php |
|||
/** |
|||
* Discover the XMPP network from the internet |
|||
*/ |
|||
class DiscoverController extends BaseController { |
|||
function load() { |
|||
$this->session_only = false; |
|||
} |
|||
|
|||
function dispatch() { |
|||
$this->page->setTitle(__('title.discover', APP_TITLE)); |
|||
|
|||
$this->page->menuAddLink(__('page.home'), 'root'); |
|||
$this->page->menuAddLink(__('page.discover'), 'discover', true); |
|||
$this->page->menuAddLink(__('page.pods'), 'pods'); |
|||
$this->page->menuAddLink(__('page.about'), 'about'); |
|||
} |
|||
} |
@ -1,21 +0,0 @@ |
|||
<?php |
|||
/** |
|||
* Explore the XMPP network |
|||
*/ |
|||
class ExploreController extends BaseController { |
|||
function load() { |
|||
$this->session_only = true; |
|||
} |
|||
|
|||
function dispatch() { |
|||
$this->page->setTitle(__('title.explore', APP_TITLE)); |
|||
|
|||
$this->page->menuAddLink(__('page.home'), 'root'); |
|||
$this->page->menuAddLink(__('page.news'), 'news'); |
|||
$this->page->menuAddLink(__('page.explore'), 'explore', true); |
|||
$this->page->menuAddLink(__('page.profile'), 'profile'); |
|||
$this->page->menuAddLink(__('page.media'), 'media'); |
|||
$this->page->menuAddLink(__('page.configuration'), 'conf', false, true); |
|||
$this->page->menuAddLink(__('page.help'), 'help', false, true); |
|||
} |
|||
} |
@ -1,11 +0,0 @@ |
|||
<?php |
|||
|
|||
class FeedController extends BaseController { |
|||
function load() { |
|||
$this->session_only = false; |
|||
$this->raw = true; |
|||
} |
|||
|
|||
function dispatch() { |
|||
} |
|||
} |
@ -1,32 +0,0 @@ |
|||
<?php |
|||
|
|||
class FriendController extends BaseController { |
|||
function load() { |
|||
$this->session_only = true; |
|||
} |
|||
|
|||
function dispatch() { |
|||
if(isset($_GET['f']) && $_GET['f'] != "" ) { |
|||
$user = new User(); |
|||
|
|||
$cd = new \modl\ContactDAO(); |
|||
$contact = $cd->get($_GET['f']); |
|||
|
|||
if(isset($contact)) |
|||
$name = $contact->getTrueName(); |
|||
else |
|||
$name = $_GET['f']; |
|||
|
|||
$this->page->setTitle(APP_TITLE.' - '.$name); |
|||
$this->page->menuAddLink(__('page.home'), 'root'); |
|||
$this->page->menuAddLink(__('page.news'), 'news'); |
|||
$this->page->menuAddLink(__('page.explore'), 'explore'); |
|||
$this->page->menuAddLink(__('page.profile'), 'profile'); |
|||
$this->page->menuAddLink(__('page.media'), 'media'); |
|||
$this->page->menuAddLink(__('page.configuration'), 'conf', false, true); |
|||
$this->page->menuAddLink(__('page.help'), 'help', false, true); |
|||
} else { |
|||
$this->name = 'main'; |
|||
} |
|||
} |
|||
} |
@ -1,23 +0,0 @@ |
|||
<?php |
|||
|
|||
class NodeController extends BaseController { |
|||
function load() { |
|||
$this->session_only = true; |
|||
} |
|||
|
|||
function dispatch() { |
|||
if(isset($_GET['s']) && $_GET['s'] != "" ) { |
|||
$this->page->setTitle(__('title.node', APP_TITLE)); |
|||
|
|||
$this->page->menuAddLink(__('page.home'), 'root'); |
|||
$this->page->menuAddLink(__('page.news'), 'news'); |
|||
$this->page->menuAddLink(__('page.explore'), 'explore'); |
|||
$this->page->menuAddLink(__('page.profile'), 'profile'); |
|||
$this->page->menuAddLink(__('page.media'), 'media'); |
|||
$this->page->menuAddLink(__('page.configuration'), 'conf', false, true); |
|||
$this->page->menuAddLink(__('page.help'), 'help', false, true); |
|||
} else { |
|||
$this->name = 'main'; |
|||
} |
|||
} |
|||
} |
@ -1,23 +0,0 @@ |
|||
<?php |
|||
|
|||
class NodeconfigController extends BaseController { |
|||
function load() { |
|||
$this->session_only = true; |
|||
} |
|||
|
|||
function dispatch() { |
|||
if(isset($_GET['s']) && $_GET['s'] != "" ) { |
|||
$this->page->setTitle(__('title.node_configuration', APP_TITLE)); |
|||
|
|||
$this->page->menuAddLink(__('page.home'), 'root'); |
|||
$this->page->menuAddLink(__('page.news'), 'news'); |
|||
$this->page->menuAddLink(__('page.explore'), 'explore'); |
|||
$this->page->menuAddLink(__('page.profile'), 'profile'); |
|||
$this->page->menuAddLink(__('page.media'), 'media'); |
|||
$this->page->menuAddLink(__('page.configuration'), 'conf', false, true); |
|||
$this->page->menuAddLink(__('page.help'), 'help', false, true); |
|||
} else { |
|||
$this->name = 'main'; |
|||
} |
|||
} |
|||
} |
@ -1,19 +0,0 @@ |
|||
<?php |
|||
|
|||
class ProfileController extends BaseController { |
|||
function load() { |
|||
$this->session_only = true; |
|||
} |
|||
|
|||
function dispatch() { |
|||
$this->page->setTitle(__('title.profile', APP_TITLE)); |
|||
|
|||
$this->page->menuAddLink(__('page.home'), 'root'); |
|||
$this->page->menuAddLink(__('page.news'), 'news'); |
|||
$this->page->menuAddLink(__('page.explore'), 'explore'); |
|||
$this->page->menuAddLink(__('page.profile'), 'profile', true); |
|||
$this->page->menuAddLink(__('page.media'), 'media'); |
|||
$this->page->menuAddLink(__('page.configuration'), 'conf', false, true); |
|||
$this->page->menuAddLink(__('page.help'), 'help', false, true); |
|||
} |
|||
} |
@ -1,23 +0,0 @@ |
|||
<?php |
|||
|
|||
class ServerController extends BaseController { |
|||
function load() { |
|||
$this->session_only = true; |
|||
} |
|||
|
|||
function dispatch() { |
|||
if(isset($_GET['s']) && $_GET['s'] != "" ) { |
|||
$this->page->setTitle(__('title.server', APP_TITLE)); |
|||
|
|||
$this->page->menuAddLink(__('page.home'), 'root'); |
|||
$this->page->menuAddLink(__('page.news'), 'news'); |
|||
$this->page->menuAddLink(__('page.explore'), 'explore'); |
|||
$this->page->menuAddLink(__('page.profile'), 'profile'); |
|||
$this->page->menuAddLink(__('page.media'), 'media'); |
|||
$this->page->menuAddLink(__('page.configuration'), 'conf', false, true); |
|||
$this->page->menuAddLink(__('page.help'), 'help', false, true); |
|||
} else { |
|||
$this->name = 'main'; |
|||
} |
|||
} |
|||
} |
@ -1,12 +0,0 @@ |
|||
<?php /* -*- mode: html -*- */ |
|||
?> |
|||
|
|||
<div id="main"> |
|||
<div id="left"> |
|||
</div> |
|||
|
|||
<div id="center"> |
|||
<?php $this->widget('Discover');?> |
|||
<div class="spacetop clear"></div> |
|||
</div> |
|||
</div> |
@ -1,24 +0,0 @@ |
|||
<?php /* -*- mode: html -*- */ |
|||
?> |
|||
<?php $this->widget('Presence');?> |
|||
<?php $this->widget('Chat');?> |
|||
<?php $this->widget('VisioExt');?> |
|||
|
|||
<div id="main"> |
|||
<div id="left"> |
|||
<?php $this->widget('Profile');?> |
|||
<?php $this->widget('Notifs');?> |
|||
<?php $this->widget('Bookmark');?> |
|||
</div> |
|||
<div id="center"> |
|||
<div class="protect black" title="<?php echo getFlagTitle("black"); ?>"></div> |
|||
<h1 class="paddedtopbottom"><i class="fa fa-globe"></i> <?php echo __('page.explore'); ?></h1> |
|||
<?php $this->widget('Hot');?> |
|||
<div class="clear"></div> |
|||
<?php $this->widget('Explore');?> |
|||
</div> |
|||
</div> |
|||
|
|||
<div id="right"> |
|||
<?php $this->widget('Roster');?> |
|||
</div> |
@ -1 +0,0 @@ |
|||
<?php $this->widget('Syndication');?> |
@ -1,21 +0,0 @@ |
|||
<?php /* -*- mode: html -*- */ |
|||
?> |
|||
<?php $this->widget('Presence');?> |
|||
<?php $this->widget('Chat');?> |
|||
<?php $this->widget('VisioExt');?> |
|||
|
|||
<div id="main"> |
|||
<div id="left"> |
|||
<?php $this->widget('Profile');?> |
|||
<?php $this->widget('Notifs');?> |
|||
<?php $this->widget('Bookmark');?> |
|||
</div> |
|||
|
|||
<div id="center"> |
|||
<?php $this->widget('Node');?> |
|||
</div> |
|||
</div> |
|||
|
|||
<div id="right"> |
|||
<?php $this->widget('Roster');?> |
|||
</div> |
@ -1,28 +0,0 @@ |
|||
<?php /* -*- mode: html -*- */ |
|||
?> |
|||
<?php $this->widget('Presence');?> |
|||
<?php $this->widget('Chat');?> |
|||
<?php $this->widget('VisioExt');?> |
|||
|
|||
<div id="head"> |
|||
|
|||
</div> |
|||
|
|||
<div id="main"> |
|||
<div id="left"> |
|||
<?php $this->widget('Profile');?> |
|||
<?php $this->widget('Notifs');?> |
|||
<?php $this->widget('Bookmark');?> |
|||
</div> |
|||
|
|||
<?php $this->widget('Tabs');?> |
|||
<div id="center"> |
|||
<?php $this->widget('NodeConfig');?> |
|||
<?php $this->widget('NodeAffiliations');?> |
|||
<?php $this->widget('NodeSubscriptions');?> |
|||
</div> |
|||
</div> |
|||
|
|||
<div id="right"> |
|||
<?php $this->widget('Roster');?> |
|||
</div> |
@ -1,27 +0,0 @@ |
|||
<?php /* -*- mode: html -*- */ |
|||
?> |
|||
<?php $this->widget('Presence');?> |
|||
<?php $this->widget('Chat');?> |
|||
<?php $this->widget('VisioExt');?> |
|||
|
|||
<div id="head"> |
|||
</div> |
|||
<div id="main"> |
|||
<div id="left"> |
|||
<?php $this->widget('Profile');?> |
|||
<?php $this->widget('Notifs');?> |
|||
<?php $this->widget('Bookmark');?> |
|||
</div> |
|||
|
|||
<?php $this->widget('Tabs');?> |
|||
|
|||
<div id="center"> |
|||
<?php $this->widget('Vcard4');?> |
|||
<?php $this->widget('Avatar');?> |
|||
<?php $this->widget('Location');?> |
|||
</div> |
|||
</div> |
|||
|
|||
<div id="right"> |
|||
<?php $this->widget('Roster');?> |
|||
</div> |
@ -1,25 +0,0 @@ |
|||
<?php /* -*- mode: html -*- */ |
|||
?> |
|||
<?php $this->widget('Presence');?> |
|||
<?php $this->widget('Chat');?> |
|||
<?php $this->widget('VisioExt');?> |
|||
|
|||
<div id="head"> |
|||
</div> |
|||
|
|||
<div id="main"> |
|||
<div id="left"> |
|||
<?php $this->widget('Profile');?> |
|||
<?php $this->widget('Notifs');?> |
|||
<?php $this->widget('Bookmark');?> |
|||
</div> |
|||
|
|||
<?php $this->widget('Tabs');?> |
|||
<div id="center"> |
|||
<?php $this->widget('ServerNodes');?> |
|||
</div> |
|||
</div> |
|||
|
|||
<div id="right"> |
|||
<?php $this->widget('Roster');?> |
|||
</div> |
@ -0,0 +1,13 @@ |
|||
<section class="scroll"> |
|||
<form name="config"> |
|||
{$form} |
|||
</form> |
|||
</section> |
|||
<div> |
|||
<a onclick="Dialog.clear()" class="button flat"> |
|||
{$c->__('button.close')} |
|||
</a> |
|||
<a onclick="Chat_ajaxSetRoomConfig(movim_parse_form('config'), '{$room}'); Dialog.clear();" class="button flat"> |
|||
{$c->__('button.save')} |
|||
</a> |
|||
</div> |
@ -1,15 +0,0 @@ |
|||
<?php |
|||
|
|||
class Discover extends WidgetCommon { |
|||
function load() |
|||
{ |
|||
|
|||
} |
|||
|
|||
function display() |
|||
{ |
|||
$cd = new \modl\ContactDAO(); |
|||
$users = $cd->getAllPublic(); |
|||
$this->view->assign('users', array_reverse($users)); |
|||
} |
|||
} |
@ -1,25 +0,0 @@ |
|||
<div id="discover"> |
|||
<h1 class="paddedtopbottom">{$c->__('last')}</h1> |
|||
|
|||
<ul class="list paddedtop"> |
|||
{loop="$users"} |
|||
<li class="block"> |
|||
<img class="avatar" src="{$value->getPhoto('xs')}"/> |
|||
<a href="{$c->route('blog', array($value->jid, 'urn:xmpp:microblog:0'))}"> |
|||
{if="$value->getAge()"} |
|||
<span class="tag blue on_desktop">{$value->getAge()}</span> |
|||
{/if} |
|||
{if="$value->getGender()"} |
|||
<span class="tag green on_desktop">{$value->getGender()}</span> |
|||
{/if} |
|||
{if="$value->getMarital()"} |
|||
<span class="tag yellow on_desktop">{$value->getMarital()}</span> |
|||
{/if} |
|||
<span class="content">{$value->getTrueName()}</span> |
|||
<span class="desc on_desktop">{$value->description|strip_tags}</span> |
|||
</a> |
|||
</li> |
|||
{/loop} |
|||
</ul> |
|||
|
|||
</div> |
@ -1 +0,0 @@ |
|||
last = 'Last registered' |
@ -1,52 +0,0 @@ |
|||
<?php |
|||
|
|||
class Explore extends WidgetCommon { |
|||
function load() { |
|||
|
|||
} |
|||
|
|||
function display() { |
|||
$this->view->assign('servers', $this->prepareServers()); |
|||
|
|||
$jid = $this->user->getLogin(); |
|||
$server = explode('@', $jid); |
|||
$this->view->assign('myserver', Route::urlize('server', $server[1])); |
|||
|
|||
$cd = new \modl\ContactDAO(); |
|||
$users = $cd->getAllPublic(); |
|||
$this->view->assign('users', array_reverse($users)); |
|||
} |
|||
|
|||
// A little filter
|
|||
private function cleanServers($servers) { |
|||
$i = 0; |
|||
foreach($servers as $c) { |
|||
if(filter_var($c->server, FILTER_VALIDATE_EMAIL)) { |
|||
unset($servers[$i]); |
|||
} elseif(count(explode('.', $c->server))<3) { |
|||
unset($servers[$i]); |
|||
} |
|||
$i++; |
|||
} |
|||
return $servers; |
|||
} |
|||
|
|||
function prepareServers() { |
|||
$nd = new \modl\ItemDAO(); |
|||
|
|||
$groups = $this->cleanServers($nd->getGroupServers()); |
|||
$chatrooms = $this->cleanServers($nd->getConferenceServers()); |
|||
|
|||
$html = ''; |
|||
|
|||
$groupsview = $this->tpl(); |
|||
$groupsview->assign('groups', $groups); |
|||
$html .= $groupsview->draw('_explore_groups', true); |
|||
|
|||
//$chatroomsview = $this->tpl();
|
|||
//$chatroomsview->assign('chatrooms', $chatrooms);
|
|||
//$html .= $chatroomsview->draw('_explore_chatrooms', true);
|
|||
|
|||
return $html; |
|||
} |
|||
} |
@ -1,9 +0,0 @@ |
|||
{loop="$chatrooms"} |
|||
<li class="block"> |
|||
<a href="{$c->route('server', $value->server)}"> |
|||
<span class="tag green">{$c->__('chatrooms')}</span> |
|||
{$value->server} |
|||
<span class="tag">{$value->number}</span> |
|||
</a> |
|||
</li> |
|||
{/loop} |
@ -1,9 +0,0 @@ |
|||
{loop="$groups"} |
|||
<li class="block"> |
|||
<a href="{$c->route('server', $value->server)}"> |
|||
<span class="tag orange on_desktop">{$c->__('groups')}</span> |
|||
<span class="tag">{$value->number}</span> |
|||
<span class="content"><i class="fa fa-sitemap"></i>{$value->server}</span> |
|||
</a> |
|||
</li> |
|||
{/loop} |
@ -1,36 +0,0 @@ |
|||
<div id="serverresult" class="padded"> |
|||
<a class="button color purple oppose icon search" href="{$myserver}">{$c->__('discover_my_server')}</a> |
|||
<h2><i class="fa fa-comments-o"></i> {$c->__('discussion_servers')}</h2> |
|||
<ul class="list"> |
|||
{$servers} |
|||
</ul> |
|||
</div> |
|||
|
|||
<div class="clear"></div> |
|||
|
|||
<div class="padded"> |
|||
<h2><i class="fa fa-clock-o"></i> {$c->__('last_registered')}</h2> |
|||
|
|||
<ul class="list"> |
|||
{loop="$users"} |
|||
<li class="block"> |
|||
<img class="avatar" src="{$value->getPhoto('xs')}"/> |
|||
<a href="{$c->route('friend', $value->jid)}"> |
|||
{if="$value->getAge()"} |
|||
<span class="tag blue on_desktop">{$value->getAge()}</span> |
|||
{/if} |
|||
{if="$value->getGender()"} |
|||
<span class="tag green on_desktop">{$value->getGender()}</span> |
|||
{/if} |
|||
{if="$value->getMarital()"} |
|||
<span class="tag yellow on_desktop">{$value->getMarital()}</span> |
|||
{/if} |
|||
<span class="content">{$value->getTrueName()}</span> |
|||
<span class="desc on_desktop">{$value->description|strip_tags}</span> |
|||
</a> |
|||
</li> |
|||
{/loop} |
|||
</ul> |
|||
|
|||
<div class="clear"></div> |
|||
</div> |
@ -1,5 +0,0 @@ |
|||
discover_my_server = 'Discover my server' |
|||
discussion_servers = 'Discussion Servers' |
|||
last_registered = 'Last registered' |
|||
groups = 'Groups' |
|||
chatrooms = 'Chatrooms' |
@ -1,149 +0,0 @@ |
|||
<?php |
|||
|
|||
use Moxl\Xec\Action\Storage\Set; |
|||
use Moxl\Xec\Action\Microblog\CommentCreateNode; |
|||
use Moxl\Xec\Action\Microblog\CreateNode; |
|||
|
|||
class Feed extends WidgetCommon { |
|||
private $_feedsize = 10; |
|||
|
|||
function load() |
|||
{ |
|||
$this->addcss('feed.css'); |
|||
|
|||
$this->registerEvent('postmicroblog', 'onStream'); |
|||
$this->registerEvent('postdeleted', 'onPostDelete'); |
|||
$this->registerEvent('postdeleteerror', 'onPostDeleteError'); |
|||
|
|||
$this->registerEvent('comment', 'onComment'); |
|||
$this->registerEvent('nocomment', 'onNoComment'); |
|||
$this->registerEvent('nocommentstream', 'onNoCommentStream'); |
|||
$this->registerEvent('commentpublisherror', 'onCommentPublishError'); |
|||
|
|||
$this->registerEvent('stream', 'onStream'); |
|||
$this->registerEvent('postpublished', 'onPostPublished'); |
|||
$this->registerEvent('postpublisherror', 'onPostPublishError'); |
|||
|
|||
$this->registerEvent('config', 'onConfig'); |
|||
} |
|||
|
|||
function display() |
|||
{ |
|||
$this->view->assign('blog_url', Route::urlize('blog', array($this->user->getLogin(), 'urn:xmpp:microblog:0'))); |
|||
$this->view->assign('feed_url', Route::urlize('feed',array($this->user->getLogin(), 'urn:xmpp:microblog:0'))); |
|||
$this->view->assign('friend_url', Route::urlize('friend',$this->user->getLogin())); |
|||
|
|||
$this->view->assign('feeds', $this->prepareFeed(-1)); |
|||
} |
|||
|
|||
function onConfig(array $data) |
|||
{ |
|||
$this->user->setConfig($data); |
|||
RPC::call('movim_fill', 'feedhead', $this->prepareHead()); |
|||
} |
|||
|
|||
function onCommentPublishError() { |
|||
$html = |
|||
'<div class="message error">'. |
|||
__('post.comment_error').' |
|||
</div>'; |
|||
RPC::call('movim_fill', 'feednotifs', $html); |
|||
} |
|||
|
|||
function onPostPublished($post) { |
|||
$html = $this->prepareFeeds(); |
|||
|
|||
RPC::call('createCommentNode', $post->nodeid); |
|||
RPC::call('movim_fill', 'feedcontent', $html); |
|||
RPC::call('createTabs'); |
|||
} |
|||
|
|||
function ajaxCreateCommentNode($parentid) { |
|||
$n = new CommentCreateNode; |
|||
$n->setTo($this->user->getLogin()) |
|||
->setParentId($parentid) |
|||
->request(); |
|||
} |
|||
|
|||
function onPostPublishError($error) { |
|||
Notification::append(null, $this->__('feed.error').$error); |
|||
} |
|||
|
|||
function prepareHead() { |
|||
$session = \Sessionx::start(); |
|||
|
|||
$cd = new Modl\CapsDAO; |
|||
$caps = $cd->get($session->host); |
|||
|
|||
if(isset($caps) && in_array('http://jabber.org/protocol/pubsub#config-node', unserialize($caps->features))) { |
|||
$html = ' |
|||
<script type="text/javascript"> |
|||
function createCommentNode(parentid) {'. |
|||
$this->call('ajaxCreateCommentNode', 'parentid[0]'). |
|||
' } |
|||
</script> |
|||
'.$this->prepareSubmitForm($this->user->getLogin(), 'urn:xmpp:microblog:0').' |
|||
<div id="feednotifs"></div>'; |
|||
} else { |
|||
$html = ''; |
|||
} |
|||
|
|||
return $html; |
|||
} |
|||
|
|||
function prepareNext($start, $html = '', $posts, $function = 'ajaxGetFeed') { |
|||
// We ask for the HTML of all the posts
|
|||
$next = $start + $this->_feedsize; |
|||
|
|||
$nexthtml = ''; |
|||
|
|||
if(sizeof($posts) > $this->_feedsize-1 && $html != '') { |
|||
$nexthtml = ' |
|||
<div class="block large"> |
|||
<div |
|||
class="older" |
|||
onclick="'.$this->call($function, "'".$next."'").'; this.parentNode.style.display = \'none\'"> |
|||
<i class="fa fa-history"></i> '. __('post.older').' |
|||
</div> |
|||
</div>'; |
|||
} else { |
|||
return ''; |
|||
} |
|||
|
|||
return $nexthtml; |
|||
} |
|||
|
|||
function prepareFeed($start) { |
|||
$pd = new \Modl\PostnDAO(); |
|||
$pl = $pd->getFeed($start+1, $this->_feedsize); |
|||
|
|||
if(isset($pl)) { |
|||
$html = $this->preparePosts($pl); |
|||
$html .= $this->prepareNext($start, $html, $pl, 'ajaxGetFeed'); |
|||
} else { |
|||
$view = $this->tpl(); |
|||
$html = $view->draw('_feed_empty', true); |
|||
} |
|||
|
|||
return $html; |
|||
} |
|||
|
|||
function ajaxGetFeed($start) { |
|||
$html = $this->prepareFeed($start); |
|||
RPC::call('movim_append', 'feedposts', $html); |
|||
RPC::commit(); |
|||
} |
|||
|
|||
function onStream($payload) { |
|||
$html = $this->prepareFeed(-1); |
|||
|
|||
if($html == '') |
|||
$html = ' |
|||
<div class="message info" style="margin: 1.5em; margin-top: 0em;">'. |
|||
__("post.no_load").' |
|||
</div>'; |
|||
|
|||
RPC::call('movim_fill', 'feedcontent', $html); |
|||
RPC::commit(); |
|||
} |
|||
} |
@ -1,4 +0,0 @@ |
|||
<div class="placeholder icon"> |
|||
<h1>{$c->__('feed.empty_title')}</h1> |
|||
<p>{$c->__('feed.empty')}</p> |
|||
</div> |
@ -1,3 +0,0 @@ |
|||
#feedhead .message { |
|||
margin: 0 1em; |
|||
} |
@ -1,31 +0,0 @@ |
|||
<div id="feed" class="spacetop tabelem" title="{$c->__('page.feed')}"> |
|||
<div id="feedhead"> |
|||
{$c->prepareHead()} |
|||
</div> |
|||
|
|||
<div class="posthead paddedbottom"> |
|||
<a |
|||
class="button color merged left" |
|||
href="{$blog_url}" |
|||
target="_blank"> |
|||
<i class="fa fa-pencil"></i> {$c->__('page.blog')} |
|||
</a><a |
|||
class="button color orange merged right" |
|||
href="{$feed_url}" |
|||
target="_blank"> |
|||
<i class="fa fa-rss"></i> {$c->__('page.feed')} (Atom) |
|||
</a> |
|||
|
|||
<a |
|||
class="button color purple oppose" |
|||
href="{$friend_url}"> |
|||
<i class="fa fa-user"></i> {$c->__('my_posts')} |
|||
</a> |
|||
</div> |
|||
|
|||
<div id="feedcontent"> |
|||
<div id="feedposts"> |
|||
{$feeds} |
|||
</div> |
|||
</div> |
|||
</div> |
@ -1,4 +0,0 @@ |
|||
my_posts = 'My Posts' |
|||
feed.error = 'An error occured : ' |
|||
feed.empty_title = 'Hi!' |
|||
feed.empty = 'This is your newsfeed, here you will see the posts published by you and your contacts.' |
@ -1,20 +0,0 @@ |
|||
<?php |
|||
class Hot extends WidgetCommon |
|||
{ |
|||
function load() |
|||
{ |
|||
} |
|||
|
|||
function display() |
|||
{ |
|||
$nd = new \modl\ItemDAO(); |
|||
|
|||
$this->view->assign('nodes', $nd->getUpdatedItems(0, 10)); |
|||
} |
|||
|
|||
function getAvatar($server, $node) { |
|||
$user = new \modl\Contact; |
|||
$user->jid = $server.$node; |
|||
return $user->getPhoto('m'); |
|||
} |
|||
} |
@ -1,25 +0,0 @@ |
|||
<div class="paddedtop"> |
|||
<h2><i class="fa fa-paper-plane-o"></i> {$c->__('explore.hot')}</h2> |
|||
|
|||
<ul class="list"> |
|||
{loop="$nodes"} |
|||
{if="!filter_var($value->server, FILTER_VALIDATE_EMAIL)"} |
|||
<li class="block"> |
|||
<a href="{$c->route('node', array($value->server, $value->node))}"> |
|||
<span class="tag gray on_desktop">{$c->__('post.updated')} {$value->num|strtotime|prepareDate}</span> |
|||
|
|||
<span class="content"> |
|||
{if="isset($value->name)"} |
|||
{$value->name} |
|||
{else} |
|||
{$value->node} |
|||
{/if} |
|||
- {$value->server} |
|||
</span> |
|||
<span class="desc on_desktop">{$value->description}</span> |
|||
</a> |
|||
</li> |
|||
{/if} |
|||
{/loop} |
|||
</ul> |
|||
</div> |
@ -1 +0,0 @@ |
|||
explore.hot = "What's Hot" |
@ -1,274 +0,0 @@ |
|||
<?php |
|||
|
|||
/** |
|||
* @package Widgets |
|||
* |
|||
* @file Node.php |
|||
* This file is part of MOVIM. |
|||
* |
|||
* @brief The items of a node |
|||
* |
|||
* @author Timothée Jaussoin <edhelas_at_gmail_dot_com> |
|||
* |
|||
* @version 1.0 |
|||
* @date 20 October 2010 |
|||
* |
|||
* Copyright (C)2010 MOVIM project |
|||
* |
|||
* See COPYING for licensing information. |
|||
*/ |
|||
|
|||
use Moxl\Xec\Action\Pubsub\GetItems; |
|||
use Moxl\Xec\Action\Pubsub\Subscribe; |
|||
use Moxl\Xec\Action\Pubsub\Unsubscribe; |
|||
use Moxl\Xec\Action\Pubsub\GetAffiliations; |
|||
use Moxl\Xec\Action\Pubsub\GetMetadata; |
|||
use Moxl\Xec\Action\Pubsub\GetSubscriptions; |
|||
|
|||
class Node extends WidgetCommon |
|||
{ |
|||
private $role; |
|||
private $_feedsize = 10; |
|||
|
|||
function load() |
|||
{ |
|||
/*$this->registerEvent('post', 'onStream'); |
|||
$this->registerEvent('stream', 'onStream'); |
|||
$this->registerEvent('nostream', 'onStream');*/ |
|||
$this->registerEvent('pubsubaffiliations', 'onPubsubAffiliations'); |
|||
$this->registerEvent('pubsubsubscribed', 'onPubsubSubscribed'); |
|||
$this->registerEvent('pubsubmetadata', 'onPubsubMetadata'); |
|||
$this->registerEvent('pubsubsubscribederror', 'onPubsubSubscribedError'); |
|||
$this->registerEvent('pubsubunsubscribed', 'onPubsubUnsubscribed'); |
|||
} |
|||
|
|||
function display() |
|||
{ |
|||
if(isset($_GET['s']) && isset($_GET['n'])) { |
|||
$this->view->assign('server', $_GET['s']); |
|||
$this->view->assign('node', $_GET['n']); |
|||
$this->view->assign('refresh', $this->call('ajaxGetItems', "'".$_GET['s']."'", "'".$_GET['n']."'")); |
|||
$this->view->assign('getaffiliations', $this->call('ajaxGetAffiliations', "'".$_GET['s']."'", "'".$_GET['n']."'")); |
|||
$this->view->assign('getmetadata', $this->call('ajaxGetMetadata', "'".$_GET['s']."'", "'".$_GET['n']."'")); |
|||
$this->view->assign('hash', md5($_GET['s'].$_GET['n'])); |
|||
$this->view->assign('items', $this->prepareNode($_GET['s'], $_GET['n'])); |
|||
$this->view->assign('metadata', $this->prepareMetadata($_GET['s'], $_GET['n'])); |
|||
|
|||
$nd = new modl\ItemDAO(); |
|||
$node = $nd->getItem($_GET['s'], $_GET['n']); |
|||
|
|||
if($node != null) |
|||
$title = $node->getName(); |
|||
else |
|||
$title = $groupid; |
|||
|
|||
$this->view->assign('title', $title); |
|||
|
|||
$this->view->assign('formpublish', $this->prepareSubmitForm($_GET['s'], $_GET['n'])); |
|||
} |
|||
} |
|||
|
|||
function onPubsubSubscribed($params) |
|||
{ |
|||
$html = $this->prepareNode($params[0], $params[1]); |
|||
RPC::call('setBookmark'); |
|||
RPC::call('movim_fill', 'node', $html); |
|||
RPC::call('movim_reload_this'); |
|||
} |
|||
|
|||
function onPubsubSubscribedError($params) |
|||
{ |
|||
$this->onPubsubSubscribed($params); |
|||
} |
|||
|
|||
function onPubsubUnsubscribed($params) |
|||
{ |
|||
$this->onPubsubSubscribed($params); |
|||
} |
|||
|
|||
function onPubsubAffiliations($params) { |
|||
foreach($params[0] as $r) { |
|||
if($r[0] == $this->user->getLogin()) |
|||
$this->role = (string)$r[1]; |
|||
} |
|||
|
|||
if($this->searchSubscription($params[1], $params[2]) |
|||
&& ($this->role == 'owner' || $this->role == 'publisher')) { |
|||
RPC::call('movim_toggle_display', '#formpublish'); |
|||
RPC::call('movim_toggle_display', '#configbutton'); |
|||
} |
|||
} |
|||
|
|||
function onPubsubMetadata($params) { |
|||
$html = $this->prepareMetadata($params[0], $params[1]); |
|||
RPC::call('movim_fill', 'metadata', $html); |
|||
} |
|||
|
|||
/*function onStream($payload) { |
|||
$html = $this->prepareNode($payload['from'], $payload['node']); |
|||
|
|||
if($html == '') |
|||
$html = __('post.no_load'); |
|||
RPC::call('movim_fill', md5($payload['from'].$payload['node']), $html); |
|||
}*/ |
|||
|
|||
function ajaxGetItems($server, $node) |
|||
{ |
|||
$pd = new \Modl\PostnDAO(); |
|||
$pd->deleteNode($server, $node); |
|||
|
|||
$r = new GetItems; |
|||
$r->setTo($server) |
|||
->setNode($node) |
|||
->request(); |
|||
} |
|||
|
|||
function ajaxSubscribe($data, $server, $node) |
|||
{ |
|||
$g = new Subscribe; |
|||
$g->setTo($server) |
|||
->setNode($node) |
|||
->setFrom($this->user->getLogin()) |
|||
//->setData($data)
|
|||
->request(); |
|||
} |
|||
|
|||
function ajaxUnsubscribe($server, $node) |
|||
{ |
|||
$sd = new \Modl\SubscriptionDAO(); |
|||
|
|||
foreach($sd->get($server, $node) as $s) { |
|||
$g = new Unsubscribe; |
|||
$g->setTo($server) |
|||
->setNode($node) |
|||
->setSubid($s->subid) |
|||
->setFrom($this->user->getLogin()) |
|||
->request(); |
|||
} |
|||
} |
|||
|
|||
function ajaxGetSubscriptions($server, $node) |
|||
{ |
|||
$r = new GetSubscriptions; |
|||
$r->setTo($server) |
|||
->setNode($node) |
|||
->setSync() |
|||
->request(); |
|||
} |
|||
|
|||
function ajaxGetAffiliations($server, $node){ |
|||
$r = new GetAffiliations; |
|||
$r->setTo($server)->setNode($node) |
|||
->request(); |
|||
} |
|||
|
|||
function ajaxGetMetadata($server, $node){ |
|||
$r = new GetMetadata; |
|||
$r->setTo($server)->setNode($node) |
|||
->request(); |
|||
} |
|||
|
|||
function prepareNode($serverid, $groupid) { |
|||
$nodeview = $this->tpl(); |
|||
$nodeview->assign('serverid', $serverid); |
|||
$nodeview->assign('groupid', $groupid); |
|||
$nodeview->assign('subscribed', $this->searchSubscription($serverid, $groupid)); |
|||
|
|||
$nodeview->assign('role', $this->role); |
|||
|
|||
$nodeview->assign('refresh', $this->call('ajaxGetItems', "'".$serverid."'", "'".$groupid."'")); |
|||
$nodeview->assign('getsubscription',$this->call('ajaxGetSubscriptions', "'".$serverid."'", "'".$groupid."'")); |
|||
$nodeview->assign('subscribe', $this->call('ajaxSubscribe', "movim_parse_form('groupsubscribe')", "'".$serverid."'", "'".$groupid."'")); |
|||
$nodeview->assign('unsubscribe', $this->call('ajaxUnsubscribe', "'".$serverid."'", "'".$groupid."'")); |
|||
|
|||
$nodeview->assign('submitform', ''); |
|||
|
|||
$nodeview->assign('posts', $this->preparePostsNode($serverid, $groupid, -1)); |
|||
|
|||
$html = $nodeview->draw('_node_content', true); |
|||
|
|||
return $html; |
|||
} |
|||
|
|||
function prepareNext($start, $html = '', $posts, $function = 'ajaxGetPostsNode', $serverid, $groupid) { |
|||
$next = $start + $this->_feedsize; |
|||
|
|||
$nexthtml = ''; |
|||
|
|||
if(sizeof($posts) > $this->_feedsize-1 && $html != '') { |
|||
$nexthtml = ' |
|||
<div class="block large"> |
|||
<div |
|||
class="older" |
|||
onclick="'.$this->call($function, "'".$serverid."'", "'".$groupid."'", "'".$next."'").'; this.parentNode.style.display = \'none\'"> |
|||
<i class="fa fa-history"></i> '. __('post.older') .' |
|||
</div> |
|||
</div>'; |
|||
} |
|||
|
|||
return $nexthtml; |
|||
} |
|||
|
|||
function prepareMetadata($server, $node) { |
|||
$nd = new modl\ItemDAO(); |
|||
$node = $nd->getItem($server, $node); |
|||
|
|||
$metadataview = $this->tpl(); |
|||
if(isset($node->name)) |
|||
$metadataview->assign('title', $node->name); |
|||
else |
|||
$metadataview->assign('title', $node->node); |
|||
$metadataview->assign('description', $node->description); |
|||
$metadataview->assign('creation', prepareDate(strtotime($node->created))); |
|||
$metadataview->assign('creator', $node->creator); |
|||
|
|||
return $metadataview->draw('_node_metadata', true); |
|||
} |
|||
|
|||
function preparePostsNode($serverid, $groupid, $start) { |
|||
$pd = new \Modl\PostnDAO(); |
|||
$pl = $pd->getNode($serverid, $groupid, $start+1, $this->_feedsize); |
|||
|
|||
if(isset($pl)) { |
|||
$html = $this->preparePosts($pl); |
|||
} else { |
|||
$view = $this->tpl(); |
|||
$html = $view->draw('_node_empty', true); |
|||
} |
|||
|
|||
$html .= $this->prepareNext($start, $html, $pl, 'ajaxGetPostsNode', $serverid, $groupid); |
|||
|
|||
return $html; |
|||
} |
|||
|
|||
function ajaxGetPostsNode($serverid, $groupid, $start) { |
|||
$html = $this->preparePostsNode($serverid, $groupid, $start); |
|||
RPC::call('movim_append', md5($serverid.$groupid), $html); |
|||
RPC::commit(); |
|||
} |
|||
|
|||
function searchSubscribed($server, $node) { |
|||
$c = Cache::c('bookmark'); |
|||
foreach($c as $bookmark) { |
|||
if( |
|||
$bookmark['type'] == 'subscription' && |
|||
$bookmark['server'] == $server && |
|||
$bookmark['node'] == $node) { |
|||
return true; |
|||
} |
|||
} |
|||
return false; |
|||
} |
|||
|
|||
function searchSubscription($server, $node) { |
|||
$sd = new \Modl\SubscriptionDAO(); |
|||
$subs = $sd->get($server, $node); |
|||
|
|||
if($subs != null) |
|||
foreach($subs as $s) { |
|||
if($s->subscription == 'subscribed') |
|||
return true; |
|||
} |
|||
return false; |
|||
} |
|||
} |
@ -1,105 +0,0 @@ |
|||
<div class="posthead paddedtopbottom"> |
|||
{if="$subscribed == true"} |
|||
<a |
|||
href="#" |
|||
class="button color" |
|||
onclick="movim_toggle_display('#groupunsubscribe')"> |
|||
<i class="fa fa-arrow-left"></i> {$c->__('node.unsubscribe')} |
|||
</a> |
|||
{else} |
|||
<a |
|||
href="#" |
|||
class="button color green" |
|||
onclick="movim_toggle_display('#groupsubscribe')"> |
|||
<i class="fa fa-arrow-right"></i> {$c->__('node.subscribe')} |
|||
</a> |
|||
{/if} |
|||
<a |
|||
class="button color merged left" |
|||
href="{$c->route('blog',array($serverid,$groupid))}" |
|||
target="_blank" |
|||
> |
|||
<i class="fa fa-pencil"></i> {$c->__('page.blog')} |
|||
</a><a |
|||
class="button color orange alone merged right" |
|||
href="{$c->route('feed',array($serverid,$groupid))}" |
|||
target="_blank" |
|||
><i class="fa fa-rss"></i></a> |
|||
<a |
|||
href="#" |
|||
onclick="{$refresh} |
|||
this.className='button color alone orange'; this.onclick=null;" |
|||
class="button color blue alone"> |
|||
<i class="fa fa-refresh"></i> |
|||
</a> |
|||
|
|||
<!-- |
|||
<a |
|||
class="button color icon yes" |
|||
onclick="{$getsubscription}" |
|||
>{$c->t('Get Subscription')}</a> |
|||
--> |
|||
<a |
|||
class="button color oppose" |
|||
style="display: none;" |
|||
id="configbutton" |
|||
href="{$c->route('nodeconfig', array($serverid,$groupid))}" |
|||
><i class="fa fa-user"></i> {$c->__('page.configuration')}</a> |
|||
</div> |
|||
|
|||
<div class="popup" id="groupsubscribe"> |
|||
<form name="groupsubscribe"> |
|||
<fieldset> |
|||
<legend>{$c->__('node.subscribe')}</legend> |
|||
<div class="element"> |
|||
<label>{$c->__('node.share_label')}</label> |
|||
<div class="checkbox"> |
|||
<input type="checkbox" name="listgroup" id="listgroup"/> |
|||
<label for="listgroup"></label> |
|||
</div> |
|||
</div> |
|||
<div class="element"> |
|||
<label for="grouptitle">{$c->__('node.nickname_label')}</label> |
|||
<input type="text" name="title" value="{$groupid}" id="grouptitle"/> |
|||
</div> |
|||
</fieldset> |
|||
<div class="menu"> |
|||
<a |
|||
class="button tiny icon yes black merged left" |
|||
onclick=" |
|||
{$subscribe} |
|||
this.onclick=null;" |
|||
>{$c->__('node.subscribe')}</a><a |
|||
class="button tiny icon no black merged right" |
|||
onclick=" |
|||
movim_toggle_display('#groupsubscribe');" |
|||
>{$c->__('button.close')}</a> |
|||
</div> |
|||
</form> |
|||
</div> |
|||
|
|||
<div class="popup" id="groupunsubscribe"> |
|||
<form name="groupunsubscribe"> |
|||
<fieldset> |
|||
<legend>{$c->__('node.unsubscribe')}</legend> |
|||
<div class="element"> |
|||
<label>{$c->__('node.sure')}</label> |
|||
</div> |
|||
</fieldset> |
|||
<div class="menu"> |
|||
<a |
|||
class="button tiny icon yes black merged left" |
|||
onclick=" |
|||
{$unsubscribe} |
|||
this.onclick=null;" |
|||
>{$c->__('node.unsubscribe')}</a><a |
|||
class="button tiny icon no black merged right" |
|||
onclick=" |
|||
movim_toggle_display('#groupunsubscribe');" |
|||
>{$c->__('button.close')}</a> |
|||
</div> |
|||
</form> |
|||
</div> |
|||
|
|||
{$submitform} |
|||
{$posts} |
@ -1,4 +0,0 @@ |
|||
<div class="placeholder padded"> |
|||
<h1>{$c->__('node.empty_title')}</h1> |
|||
<p>{$c->__('node.empty')}</p> |
|||
</div> |
@ -1,14 +0,0 @@ |
|||
<h1>{$title}</h1> |
|||
{if="isset($creation)"} |
|||
<span class="key"><i class="fa fa-clock-o"></i> </span> |
|||
<span>{$creation}</span> |
|||
{/if} |
|||
{if="isset($creator)"} |
|||
<span class="key"><i class="fa fa-user"></i> </span> |
|||
<span>{$creator}</span> |
|||
{/if} |
|||
|
|||
|
|||
{if="isset($description)"} |
|||
<p>{$description}</p> |
|||
{/if} |
@ -1,7 +0,0 @@ |
|||
node.subscribe = 'Subscribe' |
|||
node.unsubscribe = 'Unsubscribe' |
|||
node.share_label = 'Make your membership to this group public to your friends' |
|||
node.nickname_label = 'Give a nickname to this group if you want' |
|||
node.sure = 'Are you sure ?' |
|||
node.empty_title = 'Oops!' |
|||
node.empty = 'I cannot find any posts here. Try to push the refresh button.' |
@ -1,34 +0,0 @@ |
|||
<div class="tabelem protect red" id="node" title="{$c->__('page.posts')}"> |
|||
<div class="breadcrumb"> |
|||
<a href="{$c->route('explore')}"> |
|||
<i class="fa fa-globe"></i> {$c->__('page.explore')} |
|||
</a> |
|||
<a href="{$c->route('server', $server)}"> |
|||
<i class="fa fa-sitemap"></i> {$server} |
|||
</a> |
|||
<a href="{$c->route('node', array($server, $node))}"> |
|||
{$title} |
|||
</a> |
|||
<a>{$c->__('page.posts')}</a> |
|||
</div> |
|||
<div class="clear"></div> |
|||
|
|||
<div class="metadata paddedtopbottom" id="metadata"> |
|||
{$metadata} |
|||
</div> |
|||
<br /> |
|||
<div id="formpublish" style="padding-bottom: 1em; display: none;"> |
|||
{$formpublish} |
|||
</div> |
|||
<div id="{$hash}"> |
|||
{$items} |
|||
</div> |
|||
</div> |
|||
<script type="text/javascript"> |
|||
MovimWebsocket.attach(function() |
|||
{ |
|||
{$refresh} |
|||
{$getaffiliations} |
|||
{$getmetadata} |
|||
}); |
|||
</script> |
@ -1,121 +0,0 @@ |
|||
<?php |
|||
|
|||
/** |
|||
* @package Widgets |
|||
* |
|||
* @file GroupConfig.php |
|||
* This file is part of MOVIM. |
|||
* |
|||
* @brief The Group configuration widget |
|||
* |
|||
* @author Ho Christine <nodpounod@gmail.com> |
|||
* |
|||
* @version 1.0 |
|||
* @date 12 March 2013 |
|||
* |
|||
* Copyright (C)2010 MOVIM project |
|||
* |
|||
* See COPYING for licensing information. |
|||
*/ |
|||
|
|||
use Moxl\Xec\Action\Pubsub\GetConfig; |
|||
use Moxl\Xec\Action\Pubsub\SetConfig; |
|||
use Moxl\Xec\Action\Group\Delete; |
|||
|
|||
class NodeConfig extends WidgetBase |
|||
{ |
|||
|
|||
function load() |
|||
{ |
|||
$this->registerEvent('pubsubconfig', 'onConfigForm'); |
|||
$this->registerEvent('pubsubconfigsubmited', 'onGroupConfig'); |
|||
$this->registerEvent('deletionsuccess', 'onGroupDeleted'); |
|||
} |
|||
|
|||
function display() |
|||
{ |
|||
if(isset($_GET['s']) && isset($_GET['n'])) { |
|||
$nd = new modl\ItemDAO(); |
|||
$node = $nd->getItem($_GET['s'], $_GET['n']); |
|||
|
|||
if($node != null) |
|||
$title = $node->getName(); |
|||
else |
|||
$title = $groupid; |
|||
|
|||
$this->view->assign('server', $_GET['s']); |
|||
$this->view->assign('node', $_GET['n']); |
|||
$this->view->assign('name', $title); |
|||
$this->view->assign('group_config', $this->call('ajaxGroupConfig', "'".$_GET['s']."'", "'".$_GET['n']."'")); |
|||
$this->view->assign('group_delete', $this->call('ajaxGroupDelete', "'".$_GET['s']."'", "'".$_GET['n']."'")); |
|||
} |
|||
} |
|||
|
|||
function onGroupDeleted($server) { |
|||
$html = ' |
|||
<a href="'.Route::urlize('server', $server).'"> |
|||
'.$this->__('group.delete_return', $server).' |
|||
</a><br /><br />'; |
|||
|
|||
Notification::append(null, $this->__('group.deleted')); |
|||
RPC::call('movim_fill', 'handlingmessages', $html); |
|||
RPC::commit(); |
|||
} |
|||
|
|||
function onGroupConfig($stanza) { |
|||
Notification::append(null, $this->__('group.config_saved')); |
|||
RPC::commit(); |
|||
} |
|||
|
|||
function onConfigForm($form) { |
|||
$submit = $this->call('ajaxSubmitConfig', "movim_parse_form('config')", "'".$form[1]."'", "'".$form[2]."'"); |
|||
$html = ' |
|||
<form name="config">'. |
|||
$form[0]. |
|||
' |
|||
<hr /><br /> |
|||
<a |
|||
class="button color green oppose" |
|||
onclick="
|
|||
'.$submit.' |
|||
this.onclick=null; |
|||
this.style.display = \'none\' |
|||
"
|
|||
> |
|||
<i class="fa fa-check"></i> '.__('button.validate').' |
|||
</a> |
|||
<br /> |
|||
<br /> |
|||
</form>'; |
|||
|
|||
RPC::call('movim_fill', 'groupconfiguration', $html); |
|||
RPC::commit(); |
|||
} |
|||
|
|||
function ajaxGroupConfig($server, $node){ |
|||
$r = new GetConfig; |
|||
$r->setTo($server) |
|||
->setNode($node) |
|||
->request(); |
|||
} |
|||
|
|||
function ajaxGroupDelete($server, $node){ |
|||
$nd = new \Modl\ItemDAO(); |
|||
$nd->deleteItem($server, $node); |
|||
|
|||
$r = new Delete; |
|||
$r->setTo($server) |
|||
->setNode($node) |
|||
->request(); |
|||
} |
|||
|
|||
function ajaxSubmitConfig($data, $server, $node){ |
|||
$r = new SetConfig; |
|||
$r->setTo($server) |
|||
->setNode($node) |
|||
->setData($data) |
|||
->request(); |
|||
} |
|||
} |
|||
|
|||
?>
|
@ -1,5 +0,0 @@ |
|||
group.config = 'Configure your group' |
|||
group.config_saved = 'Group configuration saved' |
|||
group.delete = 'Delete this group' |
|||
group.deleted = 'Group deleted' |
|||
group.delete_return = "Return to %s's list of groups" |
@ -1,29 +0,0 @@ |
|||
<div class="breadcrumb"> |
|||
<a href="{$c->route('explore')}"> |
|||
<i class="fa fa-globe"></i> {$c->__('page.explore')} |
|||
</a> |
|||
<a href="{$c->route('server', $server)}"> |
|||
<i class="fa fa-sitemap"></i> {$server} |
|||
</a> |
|||
<a href="{$c->route('node', array($server, $node))}"> |
|||
{$name} |
|||
</a> |
|||
<a>{$c->__('page.configuration')}</a> |
|||
</div> |
|||
<div class="tabelem" title="{$c->__('page.configuration')}" id="groupconfig"> |
|||
<h1 class="paddedtopbottom"><i class="fa fa-sliders"></i> {$c->__('page.configuration')}</h1> |
|||
|
|||
<div id="groupconfiguration" class="paddedtop"> |
|||
<div id="handlingmessages"></div> |
|||
<a |
|||
class="button color green" |
|||
onclick="{$group_config} this.style.display = 'none'"> |
|||
<i class="fa fa-sliders"></i> {$c->__('group.config')} |
|||
</a> |
|||
<a |
|||
class="button color red" |
|||
onclick="{$group_delete} this.style.display = 'none'"> |
|||
<i class="fa fa-times"></i> {$c->__('group.delete')} |
|||
</a> |
|||
</div> |
|||
</div> |
@ -1,53 +0,0 @@ |
|||
<?php |
|||
|
|||
/** |
|||
* @package Widgets |
|||
* |
|||
* @file Profile.php |
|||
* This file is part of MOVIM. |
|||
* |
|||
* @brief The Profile widget |
|||
* |
|||
* @author Timothée Jaussoin <edhelas_at_gmail_dot_com> |
|||
* |
|||
* @version 1.0 |
|||
* @date 20 October 2010 |
|||
* |
|||
* Copyright (C)2010 MOVIM project |
|||
* |
|||
* See COPYING for licensing information. |
|||
*/ |
|||
|
|||
use Moxl\Xec\Action\Presence\Chat; |
|||
use Moxl\Xec\Action\Presence\Away; |
|||
use Moxl\Xec\Action\Presence\DND; |
|||
use Moxl\Xec\Action\Presence\XA; |
|||
|
|||
class Profile extends WidgetCommon |
|||
{ |
|||
private static $status; |
|||
|
|||
function load() |
|||
{ |
|||
$this->addcss('profile.css'); |
|||
$this->addjs('profile.js'); |
|||
$this->registerEvent('myvcard', 'onMyVcardReceived'); |
|||
} |
|||
|
|||
function onMyVcardReceived($vcard = false) |
|||
{ |
|||
$html = $this->prepareVcard($vcard); |
|||
RPC::call('movim_fill', 'profile', $html); |
|||
} |
|||
|
|||
function prepareVcard($vcard = false) |
|||
{ |
|||
$cd = new \Modl\ContactDAO(); |
|||
$contact = $cd->get($this->user->getLogin()); |
|||
|
|||
$vcardview = $this->tpl(); |
|||
$vcardview->assign('contact', $contact); |
|||
|
|||
return $vcardview->draw('_profile_vcard', true); |
|||
} |
|||
} |
@ -1,22 +0,0 @@ |
|||
{if="isset($contact)"} |
|||
<div class="card"> |
|||
<a href="{$c->route('friend', $contact->jid)}"> |
|||
<img src="{$contact->getPhoto('l')}"/> |
|||
<h1 style="text-decoration: none;">{$contact->getTrueName()}</h1> |
|||
</a> |
|||
<a href="{$c->route('profile')}"> |
|||
<i class="fa fa-pencil"></i> |
|||
</a> |
|||
<div class="clear"></div> |
|||
</div> |
|||
{else} |
|||
<div class="not_yet"> |
|||
{$c->__('profile.not_yet')}<br /><br /> |
|||
<a |
|||
class="button color green icon add" |
|||
style="color: white;" |
|||
href="{$c->route('profile')}"> |
|||
<i class="fa fa-user"></i> {$c->__('profile.create')} |
|||
</a> |
|||
</div> |
|||
{/if} |
@ -1,2 +0,0 @@ |
|||
profile.not_yet = 'No profile yet?' |
|||
profile.create = 'Create my profile' |
@ -1,41 +0,0 @@ |
|||
#profile_widget { |
|||
position: relative; |
|||
width: 100%; |
|||
border-bottom: 1px solid #D4D4D4; |
|||
} |
|||
|
|||
#profile_widget .card { |
|||
padding: 1em 0.5em; |
|||
box-sizing: border-box; |
|||
} |
|||
|
|||
#profile_widget .card img { |
|||
width: 3em; |
|||
border-radius: 2em; |
|||
float: left; |
|||
margin-right: 0.75em; |
|||
} |
|||
|
|||
#profile_widget .card h1 { |
|||
line-height: 1.5em; |
|||
color: #242424; |
|||
margin-top: -0.2em; |
|||
font-size: 1.2em; |
|||
} |
|||
|
|||
#profile_widget .card i { |
|||
float: right; |
|||
font-size: 1.2em; |
|||
margin-top: -1.2em; |
|||
opacity: 0.5; |
|||
} |
|||
|
|||
#profile_widget .card i:hover { |
|||
opacity: 1; |
|||
} |
|||
|
|||
#profile_widget .not_yet { |
|||
padding: 1em; |
|||
text-align: center; |
|||
} |
|||
|
@ -1,13 +0,0 @@ |
|||
function showPresence(n) |
|||
{ |
|||
n.style.display = 'none'; |
|||
buttons = document.querySelectorAll('.presence_button.merged'); |
|||
for(i = 0; i < buttons.length; i++) { |
|||
buttons[i].style.display = 'inline'; |
|||
} |
|||
} |
|||
|
|||
movim_add_onload(function() |
|||
{ |
|||
movim_textarea_autoheight(document.querySelector('#profile #status')); |
|||
}); |
@ -1,4 +0,0 @@ |
|||
<div id="profile_widget"> |
|||
{$c->prepareVcard()} |
|||
</div> |
|||
|
@ -1,165 +0,0 @@ |
|||
<?php |
|||
|
|||
/** |
|||
* @package Widgets |
|||
* |
|||
* @file ServerNodes.php |
|||
* This file is part of MOVIM. |
|||
* |
|||
* @brief The Profile widget |
|||
* |
|||
* @author Timothée Jaussoin <edhelas_at_gmail_dot_com> |
|||
* |
|||
* @version 1.0 |
|||
* @date 20 October 2010 |
|||
* |
|||
* Copyright (C)2010 MOVIM project |
|||
* |
|||
* See COPYING for licensing information. |
|||
*/ |
|||
|
|||
use Moxl\Xec\Action\Pubsub\DiscoItems; |
|||
use Moxl\Xec\Action\Group\Create; |
|||
|
|||
class ServerNodes extends WidgetCommon |
|||
{ |
|||
function load() |
|||
{ |
|||
$this->registerEvent('discoitems', 'onDiscoItems'); |
|||
$this->registerEvent('discoerror', 'onDiscoError'); |
|||
$this->registerEvent('creationsuccess', 'onCreationSuccess'); |
|||
$this->registerEvent('creationerror', 'onCreationError'); |
|||
} |
|||
|
|||
function display() |
|||
{ |
|||
if($_GET['s'] != null) { |
|||
$this->view->assign('server', $this->prepareServer($_GET['s'])); |
|||
$this->view->assign('get_nodes', $this->call('ajaxGetNodes', "'".$_GET['s']."'")); |
|||
} |
|||
} |
|||
|
|||
function onDiscoError($error) |
|||
{ |
|||
RPC::call('movim_fill', 'servernodeshead', ''); |
|||
} |
|||
|
|||
function onCreationSuccess($items) |
|||
{ |
|||
RPC::call('movim_redirect', Route::urlize('node', array($items[0], $items[1]))); |
|||
} |
|||
|
|||
function onCreationError($error) { |
|||
RPC::call('movim_fill', 'servernodes', ''); |
|||
RPC::commit(); |
|||
} |
|||
|
|||
function ajaxGetNodes($server) |
|||
{ |
|||
$nd = new \Modl\ItemDAO(); |
|||
$nd->deleteItems($server); |
|||
|
|||
$r = new DiscoItems; |
|||
$r->setTo($server)->request(); |
|||
} |
|||
|
|||
function ajaxCreateGroup($data) |
|||
{ |
|||
//make a uri of the title
|
|||
$uri = stringToUri($data['title']); |
|||
|
|||
$r = new Create; |
|||
$r->setTo($data['server'])->setNode($uri)->setData($data['title']) |
|||
->request(); |
|||
} |
|||
|
|||
function onDiscoItems($server) { |
|||
$submit = $this->call('ajaxCreateGroup', "movim_parse_form('groupCreation')"); |
|||
|
|||
list($type) = explode('.', $server); |
|||
|
|||
if(!in_array($type, array('conference', 'muc', 'discussion', 'chat'))) { |
|||
$head = ' |
|||
<a |
|||
class="button color green" |
|||
onclick="movim_toggle_display(\'#groupCreation\')"> |
|||
<i class="fa fa-plus"></i> '.t("Create a new group").' |
|||
</a>'; |
|||
|
|||
$html = ' |
|||
<div class="popup" id="groupCreation"> |
|||
<form name="groupCreation"> |
|||
<fieldset> |
|||
<legend>'.$this->__('friendly.label').'</legend> |
|||
<div class="element large mini"> |
|||
<input name="title" placeholder="'.$this->__('friendly.example').'"/> |
|||
</div> |
|||
<input type="hidden" name="server" value="'.$server.'"/> |
|||
</fieldset> |
|||
<div class="menu"> |
|||
<a |
|||
class="button color icon yes blue merged left" |
|||
onclick="'.$submit.'" |
|||
>'. |
|||
__('button.add').' |
|||
</a><a |
|||
class="button icon no black merged right" |
|||
onclick="movim_toggle_display(\'#groupCreation\')" |
|||
>'. |
|||
__('button.close').' |
|||
</a> |
|||
</div> |
|||
</form> |
|||
</div>'; |
|||
} else |
|||
$head = ''; |
|||
|
|||
$html .= $this->prepareServer($server); |
|||
|
|||
RPC::call('movim_fill', 'servernodeshead', $head); |
|||
RPC::call('movim_fill', 'servernodeslist', $html); |
|||
RPC::commit(); |
|||
} |
|||
|
|||
function prepareServer($server) { |
|||
$nd = new \Modl\ItemDAO(); |
|||
$items = $nd->getItems($server); |
|||
|
|||
if($items == null) |
|||
return ''; |
|||
|
|||
$html = '<ul class="list">'; |
|||
|
|||
foreach($items as $i) { |
|||
if(substr($i->node, 0, 20) != 'urn:xmpp:microblog:0') { |
|||
$tags = ''; |
|||
if($i->num != null) |
|||
$tags .= '<span class="tag">'.$i->num.'</span>'; |
|||
|
|||
if($i->subscription == 'subscribed') |
|||
$tags .= '<span class="tag green">'.$this->__('subscribed').'</span>'; |
|||
|
|||
$url = ''; |
|||
if($i->node != null) { |
|||
$url = 'href="'.Route::urlize('node', array($i->server, $i->node)).'"'; |
|||
} elseif($i->jid != null && !filter_var($i->jid, FILTER_VALIDATE_EMAIL)) { |
|||
$url = 'href="'.Route::urlize('server', array($i->jid)).'"'; |
|||
} else { |
|||
$tags .= '<span class="tag">'.$i->jid.'</span>'; |
|||
} |
|||
|
|||
$html .= ' |
|||
<li class="block"> |
|||
<a '.$url.'>'. |
|||
'<span class="content">'.$i->getName().'</span>'. |
|||
$tags.' |
|||
</a> |
|||
</li>'; |
|||
} |
|||
} |
|||
|
|||
$html .= '</ul>'; |
|||
|
|||
return $html; |
|||
} |
|||
} |
@ -1,4 +0,0 @@ |
|||
friendly.label = 'Give a friendly name to your group' |
|||
friendly.example = 'My Little Pony - Fan Club' |
|||
subscribed = 'Subscribed' |
|||
topics = 'Topics' |
@ -1,24 +0,0 @@ |
|||
<div class="breadcrumb protect red "> |
|||
<a href="{$c->route('explore')}"> |
|||
<i class="fa fa-globe"></i> {$c->__('page.explore')} |
|||
</a> |
|||
<a href="{$c->route('server', $_GET['s'])}"> |
|||
<i class="fa fa-sitemap"></i> {$_GET['s']} |
|||
</a> |
|||
<a>{$c->__('topics')}</a> |
|||
</div> |
|||
<div class="posthead paddedtopbottom" id="servernodeshead"> |
|||
<a |
|||
href="#" |
|||
onclick="{$get_nodes}; |
|||
this.className='button icon loading color orange'; this.onclick=null;" |
|||
class="button color"> |
|||
<i class="fa fa-refresh"></i> {$c->__('button.refresh')} |
|||
</a> |
|||
</div> |
|||
<div id="servernodes" class="tabelem paddedtop" title="{$c->__('page.server')}"> |
|||
<div id="newGroupForm"></div> |
|||
<div id="servernodeslist"> |
|||
{$server} |
|||
</div> |
|||
</div> |
@ -1,118 +0,0 @@ |
|||
<?php |
|||
|
|||
/** |
|||
* @package Widgets |
|||
* |
|||
* @file Wall.php |
|||
* This file is part of MOVIM. |
|||
* |
|||
* @brief The contact feed |
|||
* |
|||
* @author Jaussoin Timothée <edhelas_at_gmail_dot_com> |
|||
* |
|||
* @version 1.0 |
|||
* @date 30 september 2011 |
|||
* |
|||
* Copyright (C)2010 MOVIM project |
|||
* |
|||
* See COPYING for licensing information. |
|||
*/ |
|||
|
|||
use Moxl\Xec\Action\Pubsub\GetItems; |
|||
|
|||
class Wall extends WidgetCommon |
|||
{ |
|||
|
|||
function load() |
|||
{ |
|||
$this->addjs('wall.js'); |
|||
$this->registerEvent('postmicroblog', 'onStream'); |
|||
$this->registerEvent('stream', 'onStream'); |
|||
$this->registerEvent('comment', 'onComment'); |
|||
$this->registerEvent('nocomment', 'onNoComment'); |
|||
$this->registerEvent('nocommentstream', 'onNoCommentStream'); |
|||
$this->registerEvent('nostream', 'onNoStream'); |
|||
$this->registerEvent('nostreamautorized', 'onNoStreamAutorized'); |
|||
} |
|||
|
|||
function display() { |
|||
$this->view->assign('refresh', $this->call('ajaxWall', '"'.$_GET['f'].'"')); |
|||
} |
|||
|
|||
function onNoStream() { |
|||
$html = '<div style="padding: 1.5em; text-align: center;">Ain\'t Nobody Here But Us Chickens...</div>'; |
|||
RPC::call('movim_fill', 'wall', $html); |
|||
RPC::call('hideWall'); |
|||
RPC::commit(); |
|||
} |
|||
|
|||
function onNoStreamAutorized() { |
|||
$html = '<div style="padding: 1.5em; text-align: center;">I\'m sorry, Dave. I\'m afraid I can\'t do that.</div>'; |
|||
RPC::call('movim_fill', 'wall', $html); |
|||
RPC::commit(); |
|||
} |
|||
|
|||
function onStream($payload) { |
|||
$html = $this->prepareFeed(-1, $payload['from']); |
|||
if($html != '') { |
|||
RPC::call('movim_fill', stringToUri($payload['from'].$payload['node']), $html); |
|||
RPC::call('MovimMap.init'); |
|||
RPC::call('MovimMap.refresh'); |
|||
} |
|||
RPC::commit(); |
|||
} |
|||
|
|||
function prepareFeed($start, $from = false) { |
|||
if(!$from && isset($_GET['f'])) { |
|||
$from = $_GET['f']; |
|||
} elseif(!$from) { |
|||
return ''; |
|||
} |
|||
|
|||
$pd = new \Modl\PostnDAO(); |
|||
$pl = $pd->getNode($from, 'urn:xmpp:microblog:0', $start+1, 10); |
|||
|
|||
$cd = new \Modl\ContactDAO(); |
|||
$c = $cd->getRosterItem($from); |
|||
|
|||
// We ask for the HTML of all the posts
|
|||
|
|||
$htmlmessages = $this->preparePosts($pl); |
|||
|
|||
$next = $start + 10; |
|||
|
|||
$html = ''; |
|||
|
|||
if(count($pl) > 0 && $htmlmessages != false) { |
|||
$wallhead = $this->tpl(); |
|||
$wallhead->assign('start', $start); |
|||
$wallhead->assign('from', $from); |
|||
$wallhead->assign('posts', $htmlmessages); |
|||
$wallhead->assign('pl', $pl); |
|||
$wallhead->assign('refresh', $this->call('ajaxWall', "'".$from."'")); |
|||
$wallhead->assign('older', $this->call('ajaxGetFeed', "'".$next."'", "'".$from."'")); |
|||
$html = $wallhead->draw('_wall_head', true); |
|||
} |
|||
|
|||
return $html; |
|||
} |
|||
|
|||
function ajaxGetFeed($start, $from) { |
|||
RPC::call('movim_append', 'wall', $this->prepareFeed($start, $from)); |
|||
RPC::call('MovimMap.refresh'); |
|||
RPC::commit(); |
|||
} |
|||
|
|||
function ajaxWall($jid) { |
|||
$r = new GetItems; |
|||
$r->setTo($jid) |
|||
->setNode('urn:xmpp:microblog:0') |
|||
->request(); |
|||
} |
|||
|
|||
function ajaxSubscribe($jid) { |
|||
$this->xmpp->subscribeNode($jid); |
|||
} |
|||
} |
|||
|
|||
?>
|
@ -1,40 +0,0 @@ |
|||
{if="$start == -1"} |
|||
<div style="height: 13em;" id="postsmap"></div> |
|||
<div class="posthead paddedbottom"> |
|||
<a |
|||
class="button color merged left" |
|||
href="{$c->route('blog',array($from, 'urn:xmpp:microblog:0'))}" |
|||
target="_blank" |
|||
> |
|||
<i class="fa fa-pencil"></i> {$c->__('blog.title')} |
|||
</a><a |
|||
class="button color orange merged right" |
|||
href="{$c->route('feed',array($from, 'urn:xmpp:microblog:0'))}" |
|||
target="_blank" |
|||
> |
|||
<i class="fa fa-rss"></i> {$c->__('feed.title')} (Atom) |
|||
</a> |
|||
|
|||
<a |
|||
class="button color blue alone" |
|||
href="#" |
|||
onclick="{$refresh} |
|||
this.className= 'button color orange alone'; |
|||
this.onclick = 'return false;'"; |
|||
> |
|||
<i class="fa fa-refresh"></i> |
|||
</a> |
|||
</div> |
|||
{/if} |
|||
|
|||
{$posts} |
|||
|
|||
{if="count($pl) > 9"} |
|||
<div class="block large"> |
|||
<div |
|||
class="older" |
|||
onclick="{$older} this.parentNode.style.display = 'none'"> |
|||
<i class="fa fa-history"></i> {$c->__('post.older')} |
|||
</div> |
|||
</div> |
|||
{/if} |
@ -1,2 +0,0 @@ |
|||
feed.title = 'Feed' |
|||
blog.title = 'Blog' |
@ -1,10 +0,0 @@ |
|||
function hideWall() { |
|||
wall = document.querySelector("#wall"); |
|||
wall.parentNode.removeChild(wall); |
|||
createTabs(); |
|||
} |
|||
|
|||
movim_add_onload(function() { |
|||
MovimMap.init(); |
|||
MovimMap.refresh(); |
|||
}); |
@ -1,17 +0,0 @@ |
|||
<div class="tabelem" id="wall" title="{$c->__('feed.title')}" > |
|||
<div class="protect orange" title="{function="getFlagTitle("orange")"}"></div> |
|||
<div id="{function="stringToUri($_GET['f'].'urn:xmpp:microblog:0')"}"> |
|||
{$wall = $c->prepareFeed(-1, $_GET['f'])} |
|||
{if="$wall"} |
|||
{$wall} |
|||
{else} |
|||
<div style="padding: 1.5em; text-align: center;">Ain't Nobody Here But Us Chickens...</div> |
|||
<script type="text/javascript"> |
|||
MovimWebsocket.attach(function() { |
|||
{$refresh} |
|||
}); |
|||
</script> |
|||
{/if} |
|||
<div class="spacetop clear"></div> |
|||
</div> |
|||
</div> |
Write
Preview
Loading…
Cancel
Save
Reference in new issue