Example #1
0
 public function index()
 {
     $vars = $_REQUEST;
     //$this->ajaxReturn($recommend_users);
     $my_group = GroupModel::my_group($this->mid);
     if (is_array($my_group)) {
         $my_group = implode($my_group, '-');
     }
     $hot_group = GroupModel::hot_group();
     $fids = $this->my_followed(true);
     $this->assign(array('recommend_users' => $this->hot_users(), 'my_group' => $my_group, 'gid' => $my_group, 'hot_group' => $hot_group, 'fids' => $fids));
     $hot_videos = M('V')->hotVideo(5);
     foreach ($hot_videos as &$video) {
         $video = model('User')->formatForApi($video, $video['uid']);
     }
     $this->assign('hot_videos', $hot_videos);
     $this->assign('hot_blogs', M('Blog')->hotBlogs(5));
     $hot_comments = M('Comment')->getCommentList(null, 'comment_id DESC', 5)['data'];
     $this->assign('hot_comments', $hot_comments);
     $this->assign($vars);
     $this->display();
 }