当前位置:网站首页>laravel9本地安装
laravel9本地安装
2022-06-30 03:25:00 【yuanzelin8】
安装要求:
laravel9安装要求
1.php8.1以上
2.composer
Composer官方下载地址:https://getcomposer.org/
composer global require laravel/installer
先确保Composer的PHP版本为81以上。 运行以上命令安装laravel安装管理器。
laravel new 项目名称
使用该命令安装一个项目为项目名称的laravel应用(默认应该是9了,如果不是则指定一下)
如果composer安装laravel/installer后使用laravel new找不到laravel命令则需要将composer的包安装路径设置到环境变量。
通过 Composer 在命令行运行 create-project 命令来安装 Laravel:
composer create-project laravel/laravel --prefer-dist blog
3.在到此处下载最新的laravel:https://github.com/bestmomo/laravel5-example

laravel9安装遇到问题解决
问题一:
Laravel访问出错错误信息:`Warning: require(/vendor/autoload.php): failed to open stream: No such file or dire
错误信息:`Warning: require(/http/www.mywakavLee.cn/bootstrap/../vendor/autoload.php): failed to open stream: No such file or directory in /http/www.mywakavLee.cn/bootstrap/autoload.php on line 17
Fatal error: require(): Failed opening required ‘/http/www.mywakavLee.cn/bootstrap/../vendor/autoload.php’ (include_path=’.:/usr/local/lib/php’) in /http/www.mywakavLee.cn/bootstrap/autoload.php on line 17`
原因:网站根目录下缺少vendor这个存放laraver依赖包的目录
解决方法:使用composer install进行安装(没有安装过的情况下,以前安装过的话使用:composer update

问题二:
Laravel :Illuminate\Encryption\MissingAppKeyException No application encryption key has been specifi
Illuminate\Encryption\MissingAppKeyException
No application encryption key has been specified.
http://localhost:8000/
Hide solutions
Your app key is missing
Generate your application encryption key using php artisan key:generate.
问题三:
安装Laravel打开首页空白报500错误解决方法

把目录下.env.example改成.env就好
问题四:
Illuminate \ Encryption \ MissingAppKeyException PHP 8.1.7

在.env中加上:
APP_KEY=base64:lnL82E7sweHZfWOmmnUOlBWof62+XGo/aBlfGcm2zXc=
边栏推荐
- 个人PC安装软件
- Stc89c52/90c516rd/89c516rd DHT11 temperature and humidity sensor drive code
- Some common functions and precautions
- HOOK Native API
- Huawei interview question: tall and short people queue up
- Sorting method of administrative route code letter + number
- Global and Chinese market of ULTRACENTRIFUGES 2022-2028: Research Report on technology, participants, trends, market size and share
- 什么是外链和内链?
- 快速排序、聚簇索引、寻找数据中第k大的值
- Regular full match: the password consists of more than 8 digits, upper and lower case letters, and special characters
猜你喜欢
随机推荐
浅谈IDEA的优化和使用
Simulate activity startup mode in compose
Wechat applet +php to realize authorized login operation
What is the metauniverse: where are we, where are we going
Chapter 2 control structure and function (programming problem)
Knowledge points of 2022 system integration project management engineer examination: software quality assurance and quality evaluation
HOOK Native API
Golang BiliBili live broadcast bullet screen
个人PC安装软件
Auto.js学习笔记15:autojs的UI界面基础篇2
1152_ Makefile learning_ Pattern matching rules
Compile a DLL without import table
什么是外链和内链?
Mysql性能优化(6):读写分离
[live broadcast notes 0629] Concurrent Programming II: lock
快速排序、聚簇索引、寻找数据中第k大的值
LitJson解析 生成json文件 读取json文件中的字典
Use of Arthas
1150_ Makefile learning_ Duplicate name target processing in makefile
  Difference from spaces


![[qt] qmap usage details](/img/ee/6e71a3dc5b90d2d1b7f7d3f6b56221.png)





