The Cherry-project Logs Viewer
Install from composer composer require cherry-project/logs-viewer
Include Autoloader in your main file (Ex.: index.php)
require_once __DIR__ . '/vendor/autoload.php';
Logs Viewer works only with Cherry Logger logs!
Import class
use Cherry\Log\LogViewer;
Define path to your logs
define('LOGS_PATH', __DIR__ . '/var/logs');
Note: If you use Cherry Core or Cherry Framework, path must defined in config file:
{
"LOGS_PATH": "var/logs"
}
Crete class new object
$viewer = new LogViewer();
Finally you need to render the Log Viewer view:
$viewer->render();
2019 © Cherry-project