PHP code example of malvik-lab / lumen-request-log-middleware

1. Go to this page and download the library: Download malvik-lab/lumen-request-log-middleware 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/ */

    

malvik-lab / lumen-request-log-middleware example snippets


$app->middleware([
    MalvikLab\LumenRequestLogMiddleware::class,
]);

return [
    'channels' => [
        'request-log' => [
            'driver' => 'daily',
            'path' => storage_path('logs/' . php_sapi_name() . '/requests.log'),
            'days' => 30,
        ],
    ],
];