1

致命错误:未捕获的 OAuthException:(#200)需要扩展权限:read_stream 在第 1033 行的 /home/a1607618/public_html/base_facebook.php 中抛出

我的应用倾向于阅读用户墙帖

if ($user)
{
    $comments = $facebook->api('/me/home');
    d($comments);
}

function d($d){
    echo '<pre>';
    foreach ($d as $a => $b)
    {
        print "$a: $b\n";
    }
    echo '</pre>';
}

我给我的应用扩展权限:通过 Apps_ >connectme _>Permissions读取流

这是第 1033 行

protected function throwAPIException($result) {
    $e = new FacebookApiException($result);
    switch ($e->getType()) {
        // OAuth 2.0 Draft 00 style
        case 'OAuthException':
        // OAuth 2.0 Draft 10 style
        case 'invalid_token':
        $message = $e->getMessage();
        if ((strpos($message, 'Error validating access token') !== false) ||
           (strpos($message, 'Invalid OAuth access token') !== false)) {
            $this->setAccessToken(null);
            $this->user = 0;
            $this->clearAllPersistentData();
        }
    }

    throw $e;
}
4

0 回答 0