为什么在创建新项目时出现laravel错误? [英] Why do I get a laravel error while creating a new project?
问题描述
当我键入 laravel new blog
时,出现以下错误.
When I type laravel new blog
I get the following error.
在RequestException.php第113行中:
In RequestException.php line 113:
服务器错误: GET http://cabinet.laravel.com/latest.zip
导致 522原始连接超时
响应:
Server error: GET http://cabinet.laravel.com/latest.zip
resulted in a 522 Origin Connection Time-out
response:
<html>
<head><title>522 Origin Connection Time-out</title></head>
<body bgcolor="white">
<center><h1>522 Origin Conne (truncated...)
如果我键入 composer create-project --prefer-dist laravel/laravel博客
,则会出现相同的错误.
Is the same error if I typ composer create-project --prefer-dist laravel/laravel blog
.
如果我尝试去那儿,该链接将不起作用.
And the link doesn't work if I try to go there.
推荐答案
您的Laravel安装程序已经过时了.获得最新版本的唯一方法是删除并重新安装:
Your Laravel installer is very out of date. The only way to get the latest version is to remove and install again:
composer global remove laravel/installer
composer global require laravel/installer
这篇关于为什么在创建新项目时出现laravel错误?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!