PHP code example of benconstable / quick-configure

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

    

benconstable / quick-configure example snippets




// Load config
$config = new \QuickConfigure\Config();

// And do something with it!
$db = new Database($config->get('username'), $config->get('password'));



// Load development config
$config = new \QuickConfigure\Config('development');

// And do something with it!
$db = new Database($config->get('username'), $config->get('password'));

// Then get some config from a different environment
$testKey = $config->setEnv('test')->get('key');