PHP code example of akbsit / laravel-system-log

1. Go to this page and download the library: Download akbsit/laravel-system-log 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/ */

    

akbsit / laravel-system-log example snippets


use Akbsit\SystemLog\SystemLog;

$arData = [
    'some_data' => 1
];

SystemLog::write()
    ->enableSimpleInfo()
    ->setInfo(['method' => __METHOD__])
    ->setData(['$arData' => $arData])
    ->setMessage('Some log message')
    ->put();

use Akbsit\SystemLog\SystemLog;

$oSystemLog = SystemLog::read()
    ->setNameSpace(SystemLog::NAMESPACE_API);