我在使用 PHP SDK 时遇到问题:
$fql="{'query1':'SELECT uid2 FROM friend WHERE uid1=me()',
'query2':'SELECT author_uid FROM checkin WHERE author_uid IN(SELECT uid2 FROM #query1) AND page_id = $page_id'}";
$friends= $facebook->api(array(
'method' => 'fql.multiquery',
'queries' => $fql,
'access_token' => $access_token
));
而且我使用了大量的页面 ID。
当我在https://graph.facebook.com/fql/?access_token=AC&q=QUERIES中运行此脚本时, 它运行良好。
但是当我使用 php-sdk 时,有时它可以工作,但对于某些页面,它会返回错误:
FacebookApiException Object
(
[result:protected] => Array
(
[error_code] => 1
[error_msg] => An unknown error occurred
)
[message:protected] => An unknown error occurred
[string:Exception:private] =>
[code:protected] => 1
[file:protected] => /APP_PATH/base_facebook.php
[line:protected] => 1249
[trace:Exception:private] => Array
(
[0] => Array
(
[file] => /APP_PATH/base_facebook.php
[line] => 816
[function] => throwAPIException
[class] => BaseFacebook
[type] => ->
[args] => Array
(
[0] => Array
(
[error_code] => 1
[error_msg] => An unknown error occurred
)
)
)
任何人都可以帮助我吗?我不明白为什么我会收到这个错误......