0
我的FB应用程序有点问题。这是关于我总是得到错误:通过PHP API在fanpage上传视频
{"error":{"message":"(#353) Missing video file","type":"OAuthException","code":353}}
与此代码:
$post_url = "https://graph-video.facebook.com/xxx/videos?"
. "title=" . $video_title . "&description=" . $video_desc
. "&access_token=" . $access_token;
$ch = curl_init();
$data = array(
'source' => 'http://x/upload/' . $name . '.' . $type,
'file' => './upload/' . $name . '.' . $type,
'type' => 'avi',
);
curl_setopt($ch, CURLOPT_URL, $post_url);
curl_setopt($ch, CURLOPT_POST, 1);
curl_setopt($ch, CURLOPT_POSTFIELDS, $data);
$response = curl_exec($ch);
if (!$response)
{
print_r(Debug::vars(array(curl_error($ch), curl_errno($ch))));
}
curl_close($ch);
文件存在的access_token是有效的,被记录为一个应用程序,在$data
我已经试过只设置“文件”或'来源',但效果是一样的。
我很愚蠢;)寻求帮助THX – 2013-03-27 15:23:22