[Php] windows下使用composer出现SHA384 is not supported by your openssl extension

前端之家收集整理的这篇文章主要介绍了[Php] windows下使用composer出现SHA384 is not supported by your openssl extension前端之家小编觉得挺不错的,现在分享给大家,也给大家做个参考。

composer的版本太低了,需要更新composer
windows的安装使用
https://getcomposer.org/Composer-Setup.exe
报这个错Failed to decode zlib stream,把下面的composer.phar移动到PHP.exe所在目录,重试就好了

linux下用下面的命令行重新安装,windows下也可以用
PHP -r "copy('https://getcomposer.org/installer','composer-setup.PHP');"
PHP -r "if (hash_file('sha384','composer-setup.PHP') === 'a5c698ffe4b8e849a443b120cd5ba38043260d5c4023dbf93e1558871f1f07f58274fc6f4c93bcfd858c6bd0775cd8d1') { echo 'Installer verified'; } else { echo 'Installer corrupt'; unlink('composer-setup.PHP'); } echo PHP_EOL;"
PHP composer-setup.PHP
PHP -r "unlink('composer-setup.PHP');"
可以直接把目录下的composer.phar移动到/usr/bin/composer

 

PHP的版本也要比较高的版本

 

 

猜你在找的PHP相关文章