我是 Laravel 的新手,我正在尝试使用 Artisan 命令...
php artisan serve
它显示...
Laravel development server started: http://127.0.0.1:8000
但是,当我手动输入 http://127.0.0.1:8000 时,它不会自动启动它显示此错误:
RuntimeException No application encryption key has been specified.
有什么想法吗?我正在使用 Laravel 框架 5.5-dev。
最佳答案
来自 Encryption - Laravel - The PHP Framework For Web Artisans :
"Before using Laravel's encrypter, you must set a key option in your config/app.php configuration file. You should use the
php artisan key:generate
command to generate this key"
我发现在 google.com 中使用这个复杂的互联网查询:
“laravel add encrption key”(是的,即使有错字也可以使用!)
请注意,如果 .env 文件包含 key 但您仍然遇到应用程序 key 错误,则运行 php artisan config:cache
以清除并重置配置。
关于php - 未指定应用程序加密 key ,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/44839648/