3 use Illuminate\Contracts\Http\Kernel;
4 use Illuminate\Http\Request;
6 define('LARAVEL_START', microtime(true));
9 |--------------------------------------------------------------------------
10 | Check If The Application Is Under Maintenance
11 |--------------------------------------------------------------------------
13 | If the application is in maintenance / demo mode via the "down" command
14 | we will load this file so that any pre-rendered content can be shown
15 | instead of starting the framework, which could cause an exception.
19 if (file_exists($maintenance = __DIR__.'/../storage/framework/maintenance.php')) {
24 |--------------------------------------------------------------------------
25 | Register The Auto Loader
26 |--------------------------------------------------------------------------
28 | Composer provides a convenient, automatically generated class loader for
29 | this application. We just need to utilize it! We'll simply require it
30 | into the script here so we don't need to manually load our classes.
34 require __DIR__.'/../vendor/autoload.php';
37 |--------------------------------------------------------------------------
39 |--------------------------------------------------------------------------
41 | Once we have the application, we can handle the incoming request using
42 | the application's HTTP kernel. Then, we will send the response back
43 | to this client's browser, allowing them to enjoy our application.
47 $app = require_once __DIR__.'/../bootstrap/app.php';
49 $kernel = $app->make(Kernel::class);
51 $response = $kernel->handle(
52 $request = Request::capture()
55 $kernel->terminate($request, $response);