私はそれを実行しようとするプロジェクトを持っていますが、次のエラーが発生しています:
PHP Fatal error: Class 'Dotenv' not found in `/home/maras/Documents/eCodile/debtorcare/server/bootstrap/app.php on line 5`
すべての依存関係を再インストールしようphp artisan start
としましたが、うまくいきませんでした。インターネットで見つけた他の同様の問題に基づいていくつかのコマンドを実行しようとしましたが、どれも機能しました。私はすなわち試しました:
composer require vlucas/phpdotenv --prefer-dist
私はファイルを持っています.env
。
これは、エラーが配置されるファイルです。
<?php
require_once __DIR__.'/../vendor/autoload.php';
Dotenv::makeMutable();
Dotenv::load(__DIR__.'/../');
Dotenv::makeImmutable();
/*
|--------------------------------------------------------------------------
| Create The Application
|--------------------------------------------------------------------------
|
| Here we will load the environment and create the application instance
| that serves as the central piece of this framework. We'll use this
| application as an "IoC" container and router for this framework.
|
*/
$app = new Laravel\Lumen\Application(
realpath(__DIR__.'/../')
);
エラーがデータベースまたは phpMyAdmin の構成の誤りに関連している可能性はありますか? それとも、.env を間違った場所に配置してしまったのでしょうか。
このプロジェクトを開発中に実行しようとしています。