读取写入ini文件,支持动态插入值和注释
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
docs
src
tests
.gitignore
.styleci.yml
.travis.yml
README.md
composer.json
composer.lock
phpunit.xml

README.md

easy-extends

Build Status StyleCI Total Downloads Monthly Downloads

About

Installation

composer require davidnineroc/ini-parse-render

Usage

<?php

use DavidNineRoc\IniParseRender\IniManager;

$manager = IniManager::load(__DIR__.'/tests/php.ini');
$manager->set('PHP', 'extension', 'gps.dll');
/************************************
 * 默认会保存到 IniManager::load() 的参数
 * 传入的路径,如果想修改,可在 writer 方法
 * 传入参数覆盖默认路径
 */
$manager->write();

Docs

  • IniManager类是为了方便操作而出现的
  • 实际上是管理了IniReaderIniWriter这两个类
  • 这两个类的详细操作/docs目录下 docs

Todo

License

MIT