PHP code example of graze / monolog-extensions
1. Go to this page and download the library: Download graze/monolog-extensions 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/ */
graze / monolog-extensions example snippets
use Aws\DynamoDb\DynamoDbClient;
use Graze\Monolog\ErrorHandlerBuilder;
$builder = new ErrorHandlerBuilder();
$builder->setName('project-name')
->addHandler(/**$handler**/);
$builder->buildAndRegister();
use Graze\Monolog\Handler\RaygunHandler;
use Monolog\Logger;
use Raygun4php\RaygunClient;
// Create the client, using the Raygun SDK
$client = new RaygunClient('api-key');
// Create the handler
$handler = new RaygunHandler($client);
// Create the logger
$logger = new Logger('project-name', array($handler));