2017 © Pedro Peláez
 

library monolog-mysqlhandler

A handler for Monolog that sends logs to MySQL

image

jeremycurny/monolog-mysqlhandler

A handler for Monolog that sends logs to MySQL

  • Sunday, July 3, 2016
  • by jeremycurny
  • Repository
  • 1 Watchers
  • 1 Stars
  • 23 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 4 Versions
  • 15 % Grown

The README.md

monolog-mysql

MySQL Handler for Monolog, (*1)

Example

use Monolog\Handler\MysqlHandler;
use Monolog\Logger;

$logger = new Logger("myLogger");
$tableName = "logger";

$logger->pushHandler(new MysqlHandler($pdo, $tableName, Logger::DEBUG));

$logger->info("This is my first log !");

Create the table

CREATE TABLE `logger` (
  `id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
  `message` varchar(255) NOT NULL,
  `context` text NOT NULL,
  `level` int(10) unsigned NOT NULL,
  `level_name` varchar(31) NOT NULL,
  `channel` varchar(255) NOT NULL,
  `datetime` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;

License

This tool is free software and is distributed under the MIT license. Please have a look at the LICENSE file for further information., (*2)

Jeremy Curny, (*3)

The Versions

03/07 2016

dev-master

9999999-dev https://github.com/jeremycurny/monolog-mysqlhandler

A handler for Monolog that sends logs to MySQL

  Sources   Download

MIT

The Requires

 

by Jeremy Curny

database log logging monolog mysql

03/07 2016

v0.0.3

0.0.3.0 https://github.com/jeremycurny/monolog-mysqlhandler

A handler for Monolog that sends logs to MySQL

  Sources   Download

MIT

The Requires

 

by Jeremy Curny

database log logging monolog mysql

03/07 2016

v0.0.2

0.0.2.0 https://github.com/jeremycurny/monolog-mysqlhandler

A handler for Monolog that sends logs to MySQL

  Sources   Download

MIT

The Requires

 

by Jeremy Curny

database log logging monolog mysql

03/07 2016

v0.0.1

0.0.1.0 https://github.com/jeremycurny/monolog-mysqlhandler

A handler for Monolog that sends logs to MySQL

  Sources   Download

MIT

The Requires

 

by Jeremy Curny

database log logging monolog mysql