Пример #1
0
                 $list['yesterday'][] = $value;
             } else {
                 $theday = dgmdate($value['dateline'], 'Y-m-d');
                 $list[$theday][] = $value;
             }
         }
         $count++;
     }
 } else {
     $hash_datas = array();
     $more_list = array();
     $uid_feedcount = array();
     while ($value = DB::fetch($query)) {
         if (ckfriend($value['uid'], $value['friend'], $value['target_ids'])) {
             $value = mkfeed($value);
             if (ckicon_uid($value)) {
                 if ($value['dateline'] >= $_G['home_today']) {
                     $dkey = 'today';
                 } elseif ($value['dateline'] >= $_G['home_today'] - 3600 * 24) {
                     $dkey = 'yesterday';
                 } else {
                     $dkey = dgmdate($value['dateline'], 'Y-m-d');
                 }
                 $maxshownum = 3;
                 if (empty($value['uid'])) {
                     $maxshownum = 10;
                 }
                 if (empty($value['hash_data'])) {
                     if (empty($feed_users[$dkey][$value['uid']])) {
                         $feed_users[$dkey][$value['uid']] = $value;
                     }
Пример #2
0
    //个人动态
    while ($value = $_SGLOBAL['db']->fetch_array($query)) {
        if (ckfriend($value) && ckicon_uid($value)) {
            realname_set($value['uid'], $value['username']);
            $feed_list[] = $value;
        }
        $count++;
    }
    //分页
    $multi = smulti($start, $perpage, $count, $theurl);
} else {
    //好友动态
    $space['filter_icon'] = empty($space['privacy']['filter_icon']) ? array() : array_keys($space['privacy']['filter_icon']);
    while ($value = $_SGLOBAL['db']->fetch_array($query)) {
        if (empty($feed_list[$value['hash_data']][$value['uid']])) {
            if (ckfriend($value) && ckicon_uid($value)) {
                realname_set($value['uid'], $value['username']);
                $feed_list[$value['hash_data']][$value['uid']] = $value;
            }
        }
        $count++;
    }
}
$olfriendlist = $visitorlist = $task = $ols = $birthlist = $myapp = array();
$namestatus = $addfriendcount = $mtaginvitecount = $myinvitecount = $pokecount = $newreport = 0;
if ($space['self'] && empty($start)) {
    //好友申请
    $addfriendcount = getcount('friend', array('fuid' => $space['uid'], 'status' => 0));
    //群组邀请
    $mtaginvitecount = getcount('mtaginvite', array('uid' => $space['uid']));
    //应用请求