file_get_contents() returns “failed to open stream” when hitting HTTPS

前端 未结 1 880
臣服心动
臣服心动 2021-01-15 15:51

file_get_contents() is returning \"failed to open stream\" when I call it on an HTTPS URL.

Warning: file_get_contents(https://google.com) [function.file-get-         


        
相关标签:
1条回答
  • 2021-01-15 16:25

    That is probably because they are using the secure protocol https. This is strange though, in their examples, facebook is giving the similar example.

    0 讨论(0)
提交回复
热议问题