Reputation: 107
I have started a new Laravel Project and wanted to test it on my localhost... When I view the site I get an error message saying:
Warning: require(C:\xampp\htdocs\public/../Website/vendor/autoload.php): failed to open stream: No such file or directory in C:\xampp\htdocs\Website\public\index.php on line 24 Fatal Error: require(): Failed opening required 'C:\xampp\htdocs\Website\public/../Website/vendor/autoload.php' (include_path='C:\xampp\php\PEAR') in C:\xampp\htdocs\Website\public\index.php on line 24
I looked it up, but I found the autoload.php file in all folders and I already tried composer update --no-scrips
. I just don't get why it isn't loading the project.
'Website' is the name of my Laravel project folder btw.
Upvotes: 0
Views: 6629
Reputation: 1496
Turns out I didn't enable openssl in my php.ini so when I created my new project with composer it was installed from source. I changed that and ran
composer update
now the vendor folder was created
Upvotes: 0
Reputation: 107
I fixed the problem thanks to apokryfos. In the autoload file the DIR.'/../vendor/autoload.php' was changed to DIR.'/../Website/vendor/autoload.php' which was the wrong path. I don't know how this could happen, but simply deleting the 'Website/' seemed to fix the problem. Thanks again to apokryfos.
Upvotes: 1