学习php需要了解的点4 - PHP中file_get_contents函数抓取https地址出错的解决方法

来源:互联网 发布:在家网络医疗咨询 编辑:程序博客网 时间:2024/06/06 07:05
在php中,利用file_get_contents函数抓取url是https开头的网站网页内容时,会出现类似下面的错误警告:Warning: file_get_contents(https://127.0.0.1/index.php) [function.file-get-contents]: failed to open stream: Invalid argument in E:\website\blog\test.php on line 25打开php.ini找到 ;extension=php_openssl.dll ,去掉双引号”;” ,重启web服务器即可。
0 0