0
我不明白这个符号对于Facebook的文档中的GET请求(发现here):PHP进行HTTP Facebook的API GET符号
GET /oauth/access_token?
client_id={app-id}
&client_secret={app-secret}
&grant_type=client_credentials
这是什么意思在Apache中的条款以及如何我写这样的请求在PHP中?我找到了需要url的file_get_contents
和http_get
。语法如下:
$response = http_get("http://www.example.com/", array("timeout"=>1), $info);
$homepage = file_get_contents('http://www.example.com/')
我可以使用这些函数中的一个或两个?我会如何写它?我有一段时间在找这方面的好文档。
'GET/foo'就是实际的http请求的样子,而且如果你有'http:// example.com/foo',浏览器会做什么。他们也将其分成多行以便易读,就这些了。 – 2014-09-12 16:06:23
Gotcha。所以我可以这样发送请求:'file_get_contents('https://graph.facebook.com/oauth/access_token?client_id= {app-id}&client_secret = {app-secret}&grant_type = client_credentials')' – sterfry68 2014-09-12 16:11:09
几乎, 对。 – 2014-09-12 16:11:29