1. Go to this page and download the library: Download hkyss/sonar 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/ */
use hkyss\Sonar\Config;
use hkyss\Sonar\Integration\Psr15\SonarMiddleware;
use hkyss\Sonar\Sonar;
Sonar::boot(Config::fromEnv());
$pipeline->pipe(new SonarMiddleware($streamFactory));
use hkyss\Sonar\Config;
use hkyss\Sonar\Integration\Pdo\TracingPdo;
use hkyss\Sonar\Sonar;
Sonar::boot(Config::fromValue(true));
$pdo = new TracingPdo('mysql:host=localhost;dbname=app', $user, $password);
echo Sonar::inject($html);