1. Go to this page and download the library: Download aaronsaray/phproblemlogger 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/ */
aaronsaray / phproblemlogger example snippets
use AaronSaray\PHProblemLogger\Handler as Handler;
use AaronSaray\PHProblemLogger\Handler as HandlerFilter;
$monolog = $monolog; // this is an instance of a PSR-3 logger interface
$problemHandler = new Handler($monolog);
$problemHandler
->server(function(array $payload) {
return $payload;
})
->cookie(HandlerFilter::all());
use AaronSaray\PHProblemLogger\Handler as HandlerFilter;
$handler->session(HandlerFilter::all());
if (someFunctionIsTrue()) {
$handler->session(HandlerFilter::none());
}