PHP code example of lithemod / log

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

    

lithemod / log example snippets




ithe\Support\Log;

// Set the log directory
Log::dir(__DIR__ . '/logs'); // Specify your desired log directory

// Log an informational message
Log::info('This is an informational message.');

// Log a warning message
Log::warning('This is a warning message.');

// Log an error message
Log::error('This is an error message.');



ithe\Support\Log;

// Set the log directory
Log::dir(__DIR__ . '/logs');

// Log messages
Log::info('Application started.');
Log::warning('This is a warning.');
Log::error('An error occurred.');