PHP code example of netsells / logger-php

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

    

netsells / logger-php example snippets


'daily_json' => [
    'driver' => 'daily',
    'path' => env('LOG_PATH', storage_path('logs/laravel-json.log')),
    'formatter' => Netsells\Logger\LaravelLogger::class,
    'formatter_with' => [
        'project' => 'project-name',
        // optional - 'component' => 'core',
        // optional - 'subComponent' => 'php',
        // optional - 'environment' => env('APP_ENV'),
    ],
    'level' => env('LOG_LEVEL', 'debug'),
    'days' => 14,
],
bash
composer