我试着安装phpspreadysheet,但是出现了以下错误
Installation failed, deleting ./composer.json.
[RuntimeException]
No composer.json present in the current directory (./composer.json), this may
be the cause of the following exception.
[InvalidArgumentException]
Package phpoffice/phpspreadsheet has requirements incompatible with your PHP v
ersion, PHP extensions and Composer version:
- phpoffice/phpspreadsheet 1.22.0 requires ext-fileinfo * but it is not pres
ent.
- phpoffice/phpspreadsheet 1.22.0 requires ext-gd * but it is not present.有人知道怎么解决这个问题吗?我被这些错误困扰了两天,无法找到解决办法。谢谢
发布于 2022-03-16 06:25:27
打开php.ini,搜索并取消以下注释
发布于 2022-07-30 07:03:34
在visual studio中打开项目,然后单击ctr+shift+‘打开终端或打开cmd并打开项目目录
并粘贴在代码下面。
composer require phpoffice/phpspreadsheet --ignore-platform-req=ext-gd上面的语法在我身上起作用了。
https://stackoverflow.com/questions/71255993
复制相似问题