PHP code example of colibri-platform / base

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

    

colibri-platform / base example snippets




if (!is_dir(__DIR__ . '/assets')) {
    mkdir(__DIR__ . '/assets');
}

\colibri\base\Env::load(__DIR__ . '/.env');

defined('YII_DEBUG') or define('YII_DEBUG', (boolean) getenv('YII_DEBUG'));
defined('YII_ENV') or define('YII_ENV', getenv('YII_ENV')? getenv('YII_ENV') : 'prod');

bash
php -S localhost:8080