PHP code example of jacobbennett / laravel-http2serverpush
1. Go to this page and download the library: Download jacobbennett/laravel-http2serverpush library. Choose the download type require. 2. Extract the ZIP file and open the index.php. 3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
jacobbennett / laravel-http2serverpush example snippets
// app/Http/Kernel.php
...
protected $middlewareGroups = [
'web' => [
...
\JacobBennett\Http2ServerPush\Middleware\AddHttp2ServerPush::class,
...
],
...
];
php artisan vendor:publish --provider="JacobBennett\Http2ServerPush\ServiceProvider"