Error installing Sylius: “PHP Fatal error: require(): Failed opening required autoload.php”

最后都变了- 提交于 2019-12-12 04:07:05

问题


I tried to install Sylius (Symfony) with the command "(php bin/console sylius:install"), but it gives the below error:

PHP Warning: require(C:\xampp\htdocs\acme\bin/../vendor/autoload.php): failed to open stream: No such file or directory in C:\xampp\htdocs\acme\bin\console on line 16

Warning: require(C:\xampp\htdocs\acme\bin/../vendor/autoload.php): failed to open stream: No such file or directory in C:\xampp\htdocs\acme\bin\console on line 16

PHP Fatal error: require(): Failed opening required 'C:\xampp\htdocs\acme\bin/../vendor/autoload.php' (include_path='C:\xampp\php\PEAR') in C:\xampp\htdocs\acme\bin\console on line 16

Fatal error: require(): Failed opening required 'C:\xampp\htdocs\acme\bin/../vendor/autoload.php' (include_path='C:\xampp\php\PEAR') in C:\xampp\htdocs\acme\bin\console on line 16


回答1:


Please check your installed PHP version. Most likely it's 5.6. Since Sylius requires > PHP7.1 composer resolves Sylius to to the older version (something pre-beta) based on Symfony 2. Symfony3 moved console from app/ to bin/ folder.

Solution Please install PHP 7.1 locally, remove vendor folder and run composer install again



来源:https://stackoverflow.com/questions/46388614/error-installing-sylius-php-fatal-error-require-failed-opening-required-au

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!