PHP code example of maer / config-yaml-reader
1. Go to this page and download the library: Download maer/config-yaml-reader 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/ */
maer / config-yaml-reader example snippets
# Either add the reader to an existing config instance
$config->setReader('yml', new Maer\Config\Yaml\Reader);
# or you can add the reader when you instantiate the config class as a second argument
$options = [
'readers' => [
'yml' => new Maer\Config\Yaml\Reader,
],
];
$config = new Config(['/path-to-your-config.yml'], $options);