Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

ifransaad's avatar

Problem with "php artisan".

Hi. I am trying to learn laravel and setting up my environment. I downloaded the latest version of php, composer and laravel. I am getting stuck when I run the "php artisan" command in my project directory. The error is "PHP Fatal error: Uncaught Error: Class "Illuminate\Foundation\Application" not found in D:\Projects\Laravel\instagram-clone\bootstrap\app.php:14 Stack trace: #0 D:\Projects\Laravel\instagram-clone\artisan(20): require_once() #1 {main} thrown in D:\Projects\Laravel\instagram-clone\bootstrap\app.php on line 14". As I am new, I have searched a lot to solve this but nothing seems to work. I don't have the composer.lock file in my root directory. Can anyone help me with this? Thanks.

0 likes
1 reply
Nakov's avatar

There are couple of things you could try:

composer dump-autoload

composer update --no-scripts

or

composer install --no-scripts

Please or to participate in this conversation.