PHP code example of satori / debug

1. Go to this page and download the library: Download satori/debug 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/ */

    

satori / debug example snippets


class Personage
{
    protected $name;
    private $place;
    public static $something = 'important';

    public function __construct(string $name, string $place)
    {
        $this->name = $name;
        $this->place = $place;
    }
}

$alice = new Personage('Alice', 'Wonderland');

$var = [1, 'r' => 2.0000001, '3', true, null, ['x' => 3, 'y' => 5], $alice];

$f = fopen('./books/AliceInWonderland.txt', 'r');

// var_dump
dump($var, [], '', null, $f);

fclose($f);