PHP code example of cheprasov / php-simple-profiler

1. Go to this page and download the library: Download cheprasov/php-simple-profiler 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/ */

    

cheprasov / php-simple-profiler example snippets


\SimpleProfiler\Profiler::

// Path to autoloader class for SimpleProfiler
es
spl_autoload_register(
    function($class) {
        if (0 !== strpos($class, __NAMESPACE__.'\\')) {
            return;
        }
        $classPath = __DIR__ . '/' . str_replace('\\', '/', $class) . '.php';
        if (file_exists($classPath)) {
            // Disable old way to 

...
    protected function sts($file)) {
            //e);
            return true;
        }
        return false;
    }
...

$response->addHTML('<pre>' . \SimpleProfiler\Profiler::getLog() . '</pre>');