Skip to content

Commit 7086069

Browse files
authored
Update README.md
1 parent 0439ab4 commit 7086069

1 file changed

Lines changed: 6 additions & 6 deletions

File tree

README.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
PConfig 是一个使用了 PHP 编写的配置文件解析库,能够解析 PHP(array)、JSON、YAML、XML 和 INI 格式的文件,其统一了 API 操作,屏蔽了不同格式文件的解析细节,使用起来更加简单、高效。
44

5-
PConfig is a PHP library for parsing config file (php, json, xml, yaml, ini).
5+
PConfig is a PHP library for parsing config file ( e.g. php, json, xml, yaml, ini...) It has simple apis and  easy to use. You can custom your own provider and parser to process data.
66

77
## 更新 Update
88

@@ -45,7 +45,7 @@ $config->save();
4545
// json file
4646
$jsonConfig = DefaultConfigBuilder::build('config/config.json');
4747
$jsonConfig->set('homepage', 'https://github.com');
48-
$jsonConfig->setPath('config/temp_json.json'); //save as temp_json.json file
48+
$jsonConfig->setPath('config/temp_json.json'); //Save as temp_json.json file
4949
$jsonConfig->save();
5050

5151
$parser = new YamlParser();
@@ -57,7 +57,7 @@ $extConfig->save();
5757

5858
配置项的层级关系使用逗号分割,您也可以配置自定义分割规则
5959

60-
The hierarchy of configuration items is separated by commas, you an custom your own separator.
60+
The hierarchy of configuration items is separated by commas, you can custom your own separator.
6161

6262
```php
6363
<?php
@@ -66,11 +66,11 @@ use pconfig\provider\impl\FileProvider;
6666
use pconfig\parser\impl\JsonParser;
6767

6868
$config = new Config(
69-
new JsonParser(), // specify format parser
69+
new JsonParser(), // Specify format parser
7070
new FileProvider(['file' => 'config/config.php']),
7171
[
72-
Config::CONFIG_KEY_CASE => Config::KEY_CASE_LOWER, // change config keys into case lower
73-
Config::CONFIG_SEPARATOR => '.', // setting config item separator
72+
Config::CONFIG_KEY_CASE => Config::KEY_CASE_LOWER, // Change config keys into case lower
73+
Config::CONFIG_SEPARATOR => '.', // Setting config item separator
7474
]
7575
);
7676
```

0 commit comments

Comments
 (0)