PHP code example of surda / logging
1. Go to this page and download the library: Download surda/logging 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/ */
surda / logging example snippets
$stack = \GuzzleHttp\HandlerStack::create();
$stack->push(
\GuzzleHttp\Middleware::log(
new \Surda\Logging\TracyGuzzleLogger(),
new \GuzzleHttp\MessageFormatter('{request} - {response}')
)
);
$client = new \GuzzleHttp\Client([
'handler' => $stack,
...
]);