1. Go to this page and download the library: Download liquidrazor/config-loader 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/ */
liquidrazor / config-loader example snippets
$loader = new ConfigLoader(
new LoaderOptions(
configRoot: __DIR__ . '/config'
)
);
$config = $loader->load('services');
new LoaderOptions(
configRoot: '/custom/path/to/config'
);
new LoaderOptions(
configRoot: __DIR__ . '/config',
format: ConfigFormat::JSON
);