PHP code example of royalcms / laravel-request-logger

1. Go to this page and download the library: Download royalcms/laravel-request-logger 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/ */

    

royalcms / laravel-request-logger example snippets


'providers' => array(
    ...,
    Royalcms\Laravel\RequestLogger\RequestLoggerLoggerServiceProvider::class,
),

'enabled'   => true,
'format' => 'default',
'log' => [
    'channel' => 'daily', //You can create a custom log channel
    'level' => 'info',
],
'exclude' => []
shell
php artisan vendor:publish --provider="Royalcms\Laravel\RequestLogger\RequestLoggerLoggerServiceProvider"

[2020-04-03 00:00:00] local.INFO: GET http://prettus.local/user/1?param=lorem ["REQUEST"]

[2020-04-03 00:00:00] local.INFO: GET http://prettus.local/user/1?param=lorem 192.168.10.1 80 ["REQUEST"]