function ajaxAddChatroom() { $r = new Rooms(); $r->ajaxChatroomAdd(array('jid' => '*****@*****.**', 'name' => 'Movim Chatroom', 'nick' => false, 'autojoin' => 0)); $r->ajaxJoin('*****@*****.**'); RPC::call('MovimUtils.redirect', $this->route('chat')); }