PHP code example of bogosoft / configuration
1. Go to this page and download the library: Download bogosoft/configuration 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/ */
bogosoft / configuration example snippets
#
# Start with an array of values.
#
$values = [
'database:customers:host' => 'db.example.com',
'database:customers:password' => '12345',
'database:customers:port' => '3306',
'database:customers:username' => 'root'
];
#
# Convert the array into a configuration.
#
$config = new Bogosoft\Configuration\SimpleConfiguration($values);
#
# Values can be access from the configuration as if it were an array.
#
$port = $config->get('database:customers:port'); // Returns, '3306'.