PHP code example of bayfrontmedia / monolog-pdo
1. Go to this page and download the library: Download bayfrontmedia/monolog-pdo 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/ */
bayfrontmedia / monolog-pdo example snippets
use Bayfront\MonologPDO\PDOHandler;
/** @var PDO $pdo */
$handler = new PDOHandler($pdo, 'table_name');
$handler->up();
use Bayfront\MonologPDO\PDOHandler;
use Monolog\Logger;
$log = new Logger('channel_name');
/** @var PDO $pdo */
$handler = new PDOHandler($pdo, 'table_name');
$log->pushHandler($handler);