PHP code example of mydnic / laravel-allow-long-request
1. Go to this page and download the library: Download mydnic/laravel-allow-long-request 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/ */
mydnic / laravel-allow-long-request example snippets
protected $routeMiddleware = [
// ...
'allow-long-request' => \Mydnic\AllowLongRequests\Http\Middleware\AllowLongRequests::class,
]
Route::get('/', function () {
// code that takes a long time to execute
})->middleware('allow-long-request');
bash
php artisan vendor:publish --provider="Mydnic\AllowLongRequests\AllowLongRequestsServiceProvider" --tag="config"