Reputation: 1
I just downloaded composer, created new project through terminal in vscode, tried to run it and this error shows up
The Code:
require_once __DIR__ . '/vendor/autoload.php';
and also getting errors while compiling on these:
$response = $kernel->handle(
$request = Request::capture() //Undefined type 'Illuminate\Http\Request'//
)->send();
the illuminate code:
use Illuminate\Http\Request;
Upvotes: 0
Views: 8075
Reputation: 303
You should have following code for autoload.php. Basically, you're trying to look for vendor directory in the public folder, whereas it is normally placed in the base directory
require __DIR__.'/../vendor/autoload.php';
Upvotes: 1