Looking to hire Laravel developers? Try LaraJobs

laravel-config maintained by xiaolin

Description
config
Author
Last update
2018/09/06 09:55 (dev-master)
License
Links
Downloads
4

Comments
comments powered by Disqus

laravel-config

文件内容

local:
    mysql:
        host: 127.0.0.1
        port: 3306
dev:
    mysql:
        host: 127.0.0.1
        port: 3306
        
## 读取

```php
<?php
$file   = 'config.yml';
Yaml::getInstance()->load($file);

写入

<?php
$file   = 'config.yml';
$data   = Yaml::getInstance()->save($file, $data);
$data['mysql']['port'] = 3307;
yml_write($file,$data);