/autoload.php):无法打开流:

时间:2018-12-11 07:11:58

标签: php laravel

enter image description here

D:\jasmin\laravel\shop>php artisan serve
PHP Warning:  require(D:\jasmin\laravel\shop/vendor/autoload.php): failed to open stream: No such file or directory in D:\jasmin\laravel\shop\artisan on line 18

Warning: require(D:\jasmin\laravel\shop/vendor/autoload.php): failed to open stream: No such file or directory in D:\jasmin\laravel\shop\artisan on line 18
PHP Fatal error:  require(): Failed opening required 'D:\jasmin\laravel\shop/vendor/autoload.php' (include_path='D:\jasmin\xamp\php\PEAR') in D:\jasmin\laravel\shop\artisan on line 18

Fatal error: require(): Failed opening required 'D:\jasmin\laravel\shop/vendor/autoload.php' (include_path='D:\jasmin\xamp\php\PEAR') in D:\jasmin\laravel\shop\artisan on line 18

2 个答案:

答案 0 :(得分:0)

尝试从命令行运行

composer install 
or composer update

答案 1 :(得分:0)

作曲家更新

您只需要运行composer update来更新您在此文件composer.json中指定的依赖项。该命令也会生成vendor/autoload.php

  

Laravel documentation

     

Laravel利用Composer来管理其依赖项。首先,下载composer.phar的副本。拥有PHAR归档文件后,可以将其保存在本地项目目录中,也可以移至usr/local/bin以在系统上全局使用它。

     

在Windows上,您可以使用Composer Windows installer