PHPackages                             dimitrilahaye/dodo-ini-manager - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [File &amp; Storage](/categories/file-storage)
4. /
5. dimitrilahaye/dodo-ini-manager

ActiveProject[File &amp; Storage](/categories/file-storage)

dimitrilahaye/dodo-ini-manager
==============================

Awakens the dodo which is sleeping in you! And at least, manage your files.ini ! Create them, update their sections, etc.

0.1.8-beta(10y ago)06proprietaryPHPPHP &gt;=5.4

Since Apr 27Pushed 10y ago1 watchersCompare

[ Source](https://github.com/dimitrilahaye/Dodo-Ini-Manager)[ Packagist](https://packagist.org/packages/dimitrilahaye/dodo-ini-manager)[ Docs](https://github.com/dimitrilahaye/Dodo-Ini-Manager)[ RSS](/packages/dimitrilahaye-dodo-ini-manager/feed)WikiDiscussions master Synced 4w ago

READMEChangelog (10)Dependencies (2)Versions (11)Used By (0)

\#[![ ](https://camo.githubusercontent.com/d4fd315b5846dcb0c9ebb4b0c2582108bfb8c7d6a44b157e7294c4e405338412/687474703a2f2f6f72696730332e64657669616e746172742e6e65742f643030622f662f323031312f3034312f312f312f646f646f6f5f616e696d617465645f7370726974655f62795f706f6b656b6f6b732d643339376d76742e676966)](https://camo.githubusercontent.com/d4fd315b5846dcb0c9ebb4b0c2582108bfb8c7d6a44b157e7294c4e405338412/687474703a2f2f6f72696730332e64657669616e746172742e6e65742f643030622f662f323031312f3034312f312f312f646f646f6f5f616e696d617465645f7370726974655f62795f706f6b656b6f6b732d643339376d76742e676966) Dodo Ini Manager Library

Awakens the dodo which is sleeping in you!

And at least, manage your files.ini ! Create them, update their sections, etc.

Table of Contents
-----------------

[](#table-of-contents)

- [FileIni](#fileini)

    - [\_\_construct](#__construct)
    - [getPath](#getpath)
    - [rename](#rename)
    - [copy](#copy)
    - [move](#move)
    - [arrayTo](#arrayto)
    - [toArray](#toarray)
    - [jsonTo](#jsonto)
    - [toJson](#tojson)
    - [hasSection](#hassection)
    - [get](#get)
    - [set](#set)
    - [rewrite](#rewrite)
    - [rm](#rm)
    - [prepend](#prepend)
    - [append](#append)
    - [before](#before)
    - [after](#after)
    - [hasNext](#hasnext)
    - [hasPrevious](#hasprevious)
    - [getNext](#getnext)
    - [getPrevious](#getprevious)
    - [hasKey](#haskey)
    - [getKey](#getkey)
    - [setKey](#setkey)
    - [writeInKey](#writeinkey)
    - [rewriteKey](#rewritekey)
    - [rewriteInKey](#rewriteinkey)
    - [rmInKey](#rminkey)
    - [rmKey](#rmkey)
    - [keyHasNext](#keyhasnext)
    - [keyHasPrevious](#keyhasprevious)
    - [getNextKey](#getnextkey)
    - [getPreviousKey](#getpreviouskey)
    - [moveKey](#movekey)
    - [beforeKey](#beforekey)
    - [afterKey](#afterkey)
    - [prependKey](#prependkey)
    - [appendKey](#appendkey)
- [Coming Soon](#coming-soon)

FileIni
-------

[](#fileini)

General class for DodoIniManager. Provides all the methods to :

- Create and modify file.ini
- Create and modify sections
- Create and modify section's keys and their values

- Full name: \\DodoPhpLab\\DodoIniManager\\Classes\\FileIni

### \_\_construct

[](#__construct)

Method constructor. When a new FileIni object is instantiated, if file doesn't exists, we create it.

```
FileIni::__construct( string $path ): void
```

**Parameters:**

ParameterTypeDescription`$path`**string**File's path for this FileIni object.**See Also:**

- \\DodoPhpLab\\DodoIniManager\\Classes\\FileIni::createFile() - For the creation of the file.ini.

---

### getPath

[](#getpath)

Get the path for this FileIni object.

```
FileIni::getPath(  ): string
```

**Return Value:**

Returns the file's path for this FileIni object.

---

### rename

[](#rename)

Change the file's name.

```
FileIni::rename( string $name ): void
```

**Parameters:**

ParameterTypeDescription`$name`**string**New name for this file.---

### copy

[](#copy)

Create a copy of the file with another name, at the same location in file system.

```
FileIni::copy( string $name ): void
```

**Parameters:**

ParameterTypeDescription`$name`**string**Name for the copied file.---

### move

[](#move)

Change location for this file. The original file is deleted.

```
FileIni::move( string $path ): void
```

**Parameters:**

ParameterTypeDescription`$path`**string**The new path for this file.---

### arrayTo

[](#arrayto)

Update entire file with an array

```
FileIni::arrayTo( mixed[] $array ): void
```

**Parameters:**

ParameterTypeDescription`$array`**array&lt;mixed,mixed&gt;**The array content to update the file.---

### toArray

[](#toarray)

Get the parsed content of this file.

```
FileIni::toArray(  ): mixed[]
```

**Return Value:**

The parsed content of this file obtained with parse\_ini\_file() method.

---

### jsonTo

[](#jsonto)

Update entire file with a json array

```
FileIni::jsonTo( string $json ): void
```

**Parameters:**

ParameterTypeDescription`$json`**string**The json array content to update the file.---

### toJson

[](#tojson)

Get the parsed content of this file in json array format.

```
FileIni::toJson(  ): \DodoPhpLab\DodoIniManager\Classes\json
```

**Return Value:**

The parsed content of this file obtained in json array format.

---

### hasSection

[](#hassection)

Check if this file.ini has a section specified by the name passed in argument.

```
FileIni::hasSection( string $section ): boolean
```

**Parameters:**

ParameterTypeDescription`$section`**string**The name of the searched section.**Return Value:**

True if the section exists in file.ini, false if not.

---

### get

[](#get)

Get a section contained into this file.

```
FileIni::get( string $section ): mixed[]
```

**Parameters:**

ParameterTypeDescription`$section`**string**The target section's key.**Return Value:**

Returns the section from parsed file.

---

### set

[](#set)

Add a new section to this file. You are able to add an array of sub-keys for this new section.

```
FileIni::set( string $section, mixed[] $array = null ): void
```

**Parameters:**

ParameterTypeDescription`$section`**string**The section's key to add.`$array`**array&lt;mixed,mixed&gt;**An array of key =&gt; value in case we want to write element to this new section---

### rewrite

[](#rewrite)

Modify the key of a section.

```
FileIni::rewrite( string $section, string $newSection ): void
```

**Parameters:**

ParameterTypeDescription`$section`**string**The section's key to modify.`$newSection`**string**The new section's key.---

### rm

[](#rm)

Remove the section with the key passed in argument.

```
FileIni::rm( string $section ): void
```

**Parameters:**

ParameterTypeDescription`$section`**string**The section's key of the section to remove.---

### prepend

[](#prepend)

Move an entire section at the top of this file.ini

```
FileIni::prepend( string $section ): void
```

**Parameters:**

ParameterTypeDescription`$section`**string**The section's key of the section to move.---

### append

[](#append)

Move an entire section at the bottom of this file.ini

```
FileIni::append( string $section ): void
```

**Parameters:**

ParameterTypeDescription`$section`**string**The section's key of the section to move.---

### before

[](#before)

Move an entire section before another one.

```
FileIni::before( string $section, string $before ): void
```

**Parameters:**

ParameterTypeDescription`$section`**string**The section's key of the section to move.`$before`**string**The section's key of the section before wich we want to move our section.---

### after

[](#after)

Move an entire section after another one.

```
FileIni::after( string $section, string $after ): void
```

**Parameters:**

ParameterTypeDescription`$section`**string**The section's key of the section to move.`$after`**string**The section's key of the section after wich we want to move our section.---

### hasNext

[](#hasnext)

Check if this section has another section after it.

```
FileIni::hasNext( string $section ): boolean
```

**Parameters:**

ParameterTypeDescription`$section`**string**The section's key we want to evaluate.**Return Value:**

True if this section has another one after it, false if not.

---

### hasPrevious

[](#hasprevious)

Check if this section has another section before it.

```
FileIni::hasPrevious( string $section ): boolean
```

**Parameters:**

ParameterTypeDescription`$section`**string**The section's key we want to evaluate.**Return Value:**

True if this section has another one before it, false if not.

---

### getNext

[](#getnext)

Get the next section after the section'key passed in argument.

```
FileIni::getNext( string $section ): mixed[]
```

**Parameters:**

ParameterTypeDescription`$section`**string**The section's key that we want to return the following.**Return Value:**

Returns the following section from parsed file.

---

### getPrevious

[](#getprevious)

Get the next section before the section'key passed in argument.

```
FileIni::getPrevious( string $section ): mixed[]
```

**Parameters:**

ParameterTypeDescription`$section`**string**The section's key that we want to return the previous one.**Return Value:**

Returns the previous section from parsed file.

---

### hasKey

[](#haskey)

Check if the target section has a key value specified by the name passed in argument.

```
FileIni::hasKey( string $section, string $element ): boolean
```

**Parameters:**

ParameterTypeDescription`$section`**string**The name of the section where to search the key value.`$element`**string**The name of the searched key value.**Return Value:**

True if key value exists in section, false if not.

---

### getKey

[](#getkey)

Get an element contained into a section of this file.

```
FileIni::getKey( string $section, string $element ): string
```

**Parameters:**

ParameterTypeDescription`$section`**string**The section's key of the target element.`$element`**string**The target element.**Return Value:**

Returns the value of the target element

---

### setKey

[](#setkey)

Add a new element into a section of this file. You are able to add an array of sub-keys in second argument in order to add many elements into the target section or just a string in order to add a simple sub-key.

```
FileIni::setKey( string $section, mixed[] $element ): void
```

**Parameters:**

ParameterTypeDescription`$section`**string**The section's key of the target element.`$element`**array&lt;mixed,mixed&gt;**The target element.---

### writeInKey

[](#writeinkey)

Add a value into the element of a section into this file.

```
FileIni::writeInKey( string $section, string $element, string $content ): void
```

**Parameters:**

ParameterTypeDescription`$section`**string**The section's key of the target element.`$element`**string**The target element.`$content`**string**The value to write in the element.---

### rewriteKey

[](#rewritekey)

Modify the element's key of a section into this file.

```
FileIni::rewriteKey( string $section, string $element, string $newElement ): void
```

**Parameters:**

ParameterTypeDescription`$section`**string**The section's key of the target element.`$element`**string**The target element.`$newElement`**string**The new name for the target element.---

### rewriteInKey

[](#rewriteinkey)

Overwrite a value into the element of a section into this file.

```
FileIni::rewriteInKey( string $section, string $element, string $content ): void
```

**Parameters:**

ParameterTypeDescription`$section`**string**The section's key of the target element.`$element`**string**The target element.`$content`**string**The value to write in the element.---

### rmInKey

[](#rminkey)

Remove the value into a target element in a section of this file.

```
FileIni::rmInKey( string $section, string $element ): void
```

**Parameters:**

ParameterTypeDescription`$section`**string**The section's key of the target element.`$element`**string**The target element.---

### rmKey

[](#rmkey)

Remove the entire element's key/value into a section of this file.

```
FileIni::rmKey( string $section, string $element ): void
```

**Parameters:**

ParameterTypeDescription`$section`**string**The section's key of the target element.`$element`**string**The target element to remove.---

### keyHasNext

[](#keyhasnext)

Check if this section's element has another element after it.

```
FileIni::keyHasNext( string $section, string $element ): boolean
```

**Parameters:**

ParameterTypeDescription`$section`**string**The section's key of the target element.`$element`**string**The target element to evaluate.**Return Value:**

True if this element has another one after it, false if not.

---

### keyHasPrevious

[](#keyhasprevious)

Check if this section's element has another element before it.

```
FileIni::keyHasPrevious( string $section, string $element ): boolean
```

**Parameters:**

ParameterTypeDescription`$section`**string**The section's key of the target element.`$element`**string**The target element to evaluate.**Return Value:**

True if this element has another one before it, false if not.

---

### getNextKey

[](#getnextkey)

Get the next element after the element'key passed in argument.

```
FileIni::getNextKey( string $section, string $element ): string
```

**Parameters:**

ParameterTypeDescription`$section`**string**The section's key of the target element.`$element`**string**The section's element's key that we want to return the following.**Return Value:**

Returns the following element from parsed file.

---

### getPreviousKey

[](#getpreviouskey)

Get the element before the element'key passed in argument.

```
FileIni::getPreviousKey( string $section, string $element ): string
```

**Parameters:**

ParameterTypeDescription`$section`**string**The section's key of the target element.`$element`**string**The section's element's key that we want to return the previous one.**Return Value:**

Returns the previous element from parsed file.

---

### moveKey

[](#movekey)

Move the element into another section. The original element is deleted.

```
FileIni::moveKey( string $section, string $element, string $newSection ): void
```

**Parameters:**

ParameterTypeDescription`$section`**string**The section's key of the target element.`$element`**string**The element's key to move.`$newSection`**string**The section's key where to move the element.---

### beforeKey

[](#beforekey)

Move an entire element's key/value before another one.

```
FileIni::beforeKey( string $section, string $element, string $before ): void
```

**Parameters:**

ParameterTypeDescription`$section`**string**The section's key of the element to move.`$element`**string**The element's key of the element to move.`$before`**string**The element's key before wich we want to move our element.---

### afterKey

[](#afterkey)

Move an entire element's key/value after another one.

```
FileIni::afterKey( string $section, string $element, string $after ): void
```

**Parameters:**

ParameterTypeDescription`$section`**string**The section's key of the element to move.`$element`**string**The element's key of the element to move.`$after`**string**The element's key after wich we want to move our element.---

### prependKey

[](#prependkey)

Move an entire element at the top of its section.

```
FileIni::prependKey( string $section, string $element ): void
```

**Parameters:**

ParameterTypeDescription`$section`**string**The section's key of the section's element to move.`$element`**string**The element's key to move.---

### appendKey

[](#appendkey)

Move an entire element at the bottom of its section.

```
FileIni::appendKey( string $section, string $element ): void
```

**Parameters:**

ParameterTypeDescription`$section`**string**The section's key of the section's element to move.`$element`**string**The element's key to move.---

[![ ](https://camo.githubusercontent.com/d4fd315b5846dcb0c9ebb4b0c2582108bfb8c7d6a44b157e7294c4e405338412/687474703a2f2f6f72696730332e64657669616e746172742e6e65742f643030622f662f323031312f3034312f312f312f646f646f6f5f616e696d617465645f7370726974655f62795f706f6b656b6f6b732d643339376d76742e676966)](https://camo.githubusercontent.com/d4fd315b5846dcb0c9ebb4b0c2582108bfb8c7d6a44b157e7294c4e405338412/687474703a2f2f6f72696730332e64657669616e746172742e6e65742f643030622f662f323031312f3034312f312f312f646f646f6f5f616e696d617465645f7370726974655f62795f706f6b656b6f6b732d643339376d76742e676966) Coming Soon
----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

[](#-coming-soon)

> - Manage exceptions (section, element not found..)
> - Add sample code in README.md
> - Add new cool methods : suggestions are welcome and usefull ;)

---

> This document was automatically generated from source code comments on 2016-04-27 using [phpDocumentor](http://www.phpdoc.org/) and [cvuorinen/phpdoc-markdown-public](https://github.com/cvuorinen/phpdoc-markdown-public)

###  Health Score

22

—

LowBetter than 21% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity4

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity50

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~1 days

Total

10

Last Release

3705d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/7722597?v=4)[Dimitri Lahaye](/maintainers/dimitrilahaye)[@dimitrilahaye](https://github.com/dimitrilahaye)

---

Top Contributors

[![dimitrilahaye](https://avatars.githubusercontent.com/u/7722597?v=4)](https://github.com/dimitrilahaye "dimitrilahaye (32 commits)")

---

Tags

parserfilemanagersectionsinidodo

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/dimitrilahaye-dodo-ini-manager/health.svg)

```
[![Health](https://phpackages.com/badges/dimitrilahaye-dodo-ini-manager/health.svg)](https://phpackages.com/packages/dimitrilahaye-dodo-ini-manager)
```

###  Alternatives

[unisharp/laravel-filemanager

A file upload/editor intended for use with Laravel 5 to 10 and CKEditor / TinyMCE

2.1k3.4M81](/packages/unisharp-laravel-filemanager)[alexusmai/laravel-file-manager

File manager for Laravel

1.2k786.7k9](/packages/alexusmai-laravel-file-manager)[servocoder/richfilemanager

RichFilemanager - highly customizable open-source file manager

90963.7k2](/packages/servocoder-richfilemanager)[oneduo/nova-file-manager

A handy file manager tool for Laravel Nova

159399.9k2](/packages/oneduo-nova-file-manager)[illuminatech/multipart-middleware

'multipart/form-data' parser middleware for Laravel

35280.8k](/packages/illuminatech-multipart-middleware)[itskodinger/midia

Simple Media manager for your Laravel project

1416.0k](/packages/itskodinger-midia)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
