【发布时间】:2013-03-02 10:59:27
【问题描述】:
在下面的代码中我得到错误failed to open stream: HTTP request failed! HTTP/1.0 400 Bad Request
$url = "https://graph.facebook.com/$orderId";
$url_with_token = $url . "?access_token=$token";
$result= json_decode(file_get_contents($url_with_token));
请告诉我哪里出错了
【问题讨论】:
-
请检查令牌。
-
$orderId或$token可能有问题?在之前打印$url_with_token,看看那里有什么。 -
当我在浏览器中粘贴
$url_with_token时,我得到了正确的结果
标签: php facebook file-get-contents