鍍金池/ 問答/PHP/ php file_get_contents

php file_get_contents

我的php腳本中發(fā)送post請求,用file_get_contents(url),url是別的網(wǎng)站的接口,訪問接口成功,也拿到了返回的成功數(shù)據(jù),但當我在瀏覽器的控制臺的network雙擊php腳本時,瀏覽器打開的新網(wǎng)頁顯示:
Warning: file_get_contents(url) [function.file-get-contents]: failed to open stream: HTTP request failed!
這是怎么回事呢?服務器是本地的apache。

回答
編輯回答
初念

你的問題描述不清楚
這里有個鏈接你看看能解決你的問題嗎 http://blog.csdn.net/aerchi/a...

2017年4月25日 17:55