Skip to content

mhndev/config

 
 

Repository files navigation

Config

forked from hassankhan/config the one and only difference which I made is : access config values by file name

<?php
use Noodlehaus\Config;

// Load all supported files in a directory
$conf = new Config(__DIR__ . '/config');

consider in mentioned path we have multiple config file and one of them is mail.php and it's content is as follow

<?php
return [ 
       'driver'=>'file'
];

now you can access this variable like follow :

// Get value using key
$debug = $conf->get('mail.driver');

About

Config is a lightweight configuration file loader that supports PHP, INI, XML, JSON, and YAML files

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • PHP 100.0%