示例#1
0
            $users = C::t('home_follow')->fetch_all_by_uid_followuid($_G['uid'], array_keys($recommend));
            foreach ($users as $ruid => $user) {
                if (isset($recommend[$ruid])) {
                    unset($recommend[$ruid]);
                }
            }
        }
    }
    $navactives = array('feed' => ' class="a"');
    $actives = array($view => ' class="a"');
    list($seccodecheck, $secqaacheck) = seccheck('publish');
} elseif ($do == 'view') {
    $list = getfollowfeed($uid, 'self', false, $start, $perpage);
    if (empty($list['feed'])) {
        $primary = 0;
        $list = getfollowfeed($uid, 'self', true, $start, $perpage);
        if (empty($list['user'])) {
            $archiver = 0;
        }
    }
    if (!isset($_G['cache']['forums'])) {
        loadcache('forums');
    }
    if (helper_access::check_module('follow')) {
        $followerlist = C::t('home_follow')->fetch_all_following_by_uid($uid, 0, 9);
    }
    $seccodecheck = $_G['setting']['seccodestatus'] & 4 && (!$_G['setting']['seccodedata']['minposts'] || getuserprofile('posts') < $_G['setting']['seccodedata']['minposts']);
    $secqaacheck = $_G['setting']['secqaa']['status'] & 2 && (!$_G['setting']['secqaa']['minposts'] || getuserprofile('posts') < $_G['setting']['secqaa']['minposts']);
} elseif ($do == 'follower') {
    $count = C::t('home_follow')->count_follow_user($uid, 1);
    if ($viewself && !empty($_G['member']['newprompt_num']['follower'])) {
示例#2
0
    checkfollowfeed();
    exit;
} elseif ($op == 'getfeed') {
    $archiver = $_GET['archiver'] ? true : false;
    $uid = intval($_GET['uid']);
    $page = empty($_GET['page']) ? 1 : intval($_GET['page']);
    if ($page < 1) {
        $page = 1;
    }
    $perpage = 20;
    $start = ($page - 1) * $perpage;
    if ($uid) {
        $list = getfollowfeed($uid, 'self', $archiver, $start, $perpage);
    } else {
        $type = in_array($_GET['viewtype'], array('special', 'follow', 'other')) ? $_GET['viewtype'] : 'follow';
        $list = getfollowfeed($type == 'other' ? 0 : $_G['uid'], $type, $archiver, $start, $perpage);
    }
    if (empty($list['feed'])) {
        $list = false;
    }
    if (!isset($_G['cache']['forums'])) {
        loadcache('forums');
    }
} elseif ($op == 'delete') {
    $archiver = false;
    $feed = C::t('home_follow_feed')->fetch_by_feedid($_GET['feedid']);
    if (empty($feed)) {
        $feed = C::t('home_follow_feed')->fetch_by_feedid($_GET['feedid'], true);
        $archiver = true;
    }
    if (empty($feed)) {