我正在学习Laravel 5,我想在Laravel 5.8中安装LaravelCollective/HTML。我发现(在这里和其他地方(有几种方法可以做到这一点。但是,我没有成功地尝试了它们。我在Windows 10上使用XAMPP 3.2.2作为本地服务器。
我尝试过的解决方案和我得到的。
解决方案1
首先,我添加了此行
"laravelcollective/html": "5.8.*"
到我的Composer.json的需要数组,将其保存。而且,在我的项目目录中,我运行了命令
composer update
结果1
PS C:xampphtdocsmylaravel> composer update
Loading composer repositories with package information
Updating dependencies (including require-dev)
上面是我终端的副本和粘贴。该过程在该级别停止。
解决方案2
我尝试通过运行:
来安装LaravelCollective/HTML软件包 composer require "laravelcollective/html:5.8.*"
在此中,我尝试了其他一些参数 Composer需要,例如:
composer require 'laravelcollective/html:5.8.*'
composer require "laravelcollective/html:5.8.*"
composer require "laravelcollective/html:5.8.0"
composer require 'laravelcollective/html:5.8.0'
composer require 'laravelcollective/html:^5.8.0'
composer require "laravelcollective/html:^5.8.0"
即使是指示版本的参数:
composer require 'laravelcollective/html'
所有人都给出相同的结果
结果2
PS C:xampphtdocsmylaravel> composer require 'laravelcollective/html:^5.8.0'
[ComposerDownloaderTransportException]
The "https://packagist.org/p/provider-2019-04%241d52886260d9f0e30a70676feea97a605da410b08fd409cad3de1a04bb47c878.json" file could not be downloaded (HTTP
/1.1 404 Not Found)
require [--dev] [--prefer-source] [--prefer-dist] [--no-progress] [--no-suggest] [--no-update] [--no-scripts] [--update-no-dev] [--update-with-dependencies] [--update-with-all-dependencies] [--ignore-platform-reqs] [--prefer-stable] [--prefer-lowest] [--sort-packages] [-o|--optimize-autoloader] [-a|--classmap-authoritative] [--apcu-autoloader] [--] [<packages>]...
解决方案结果的图像
任何帮助都将不胜感激
尝试添加此版本
"laravelcollective/html": "^5.4.0"
然后执行
composer update