Example #1
0
$newSpace = new PwSpace($uid);
if (!($space =& $newSpace->getInfo())) {
    Showmsg('您访问的空间不存在!');
}
$inv_config = L::config(null, 'inv_config');
if (GetCookie('userads') && $inv_linkopen && $inv_linktype == '0') {
    list($uid, $a) = explode("\t", GetCookie('userads'));
    if (is_numeric($uid) || $a && strlen($a) < 16) {
        require_once R_P . 'require/userads.php';
    }
}
$newSpace->initSet();
$indexRight = $newSpace->viewRight('index');
$indexValue = $newSpace->getPrivacyByKey('index');
if ($indexRight) {
    $data = $newSpace->layout();
    //var_dump($data);
} else {
    $data = array(0 => $newSpace->getSpaceData(array('info' => 1)));
}
$siteName = getSiteName('o');
$uSeo = USeo::getInstance();
$uSeo->set($space['name'] . ' - ' . $siteName, $space['name'], $space['name'] . ',' . $siteName);
if ($winduid && !$space['isMe']) {
    //邀请处理
    if (GetCookie('o_invite') && $db_modes['o']['ifopen'] == 1) {
        list($o_u, $hash, $app) = explode("\t", GetCookie('o_invite'));
        if (is_numeric($o_u) && strlen($hash) == 18) {
            require_once R_P . 'require/o_invite.php';
        }
    }