require ('facebook.php');
define('FACEBOOK_APP_ID',"My_ID");
define('FACEBOOK_SECRET',"My_Secret");
define('REDIRECT_URI',"My_Website");
define('PERMISSIONS_REQUIRED', "publish_stream");
$facebook = new Facebook(array(
'appId' => FACEBOOK_APP_ID,
'secret' => FACEBOOK_SECRET,
'cookie' => true
));
$access_token = $facebook->getAccessToken();
$query = mysql_query("SELECT `title` FROM `tentego_img` WHERE `id` = ".intval($_GET['id'])."");
$r = mysql_fetch_array($query);
$link = $_SERVER['SERVER_NAME'].$_SERVER['REQUEST_URI'];
$facebook->api('/me/feed', 'POST',
array(
'link' => $link,
'message' => $r[0]
));
错误:致命错误:未捕获 OAuthException:必须使用活动访问令牌来查询有关当前用户的信息。
请帮忙。