PHP code example of smalot / cerbere

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

    

smalot / cerbere example snippets




// Detected composer dir according to OS platform.
if (($home_dir = getenv('HOME')) && (strtoupper(substr(PHP_OS, 0, 3)) === 'WIN')) {
    $composer_dir = $home_dir . '/AppData/Roaming/Composer';
} else {
    $composer_dir = $home_dir . '/.composer';
}

// Include composer autoload file and declare Cerbere commands.
if (is_file($composer_dir . '/vendor/autoload.php') && 
    is_dir($composer_dir . '/vendor/smalot/cerbere/commands')) {