PHP code example of chinacn / ini-parser
1. Go to this page and download the library: Download chinacn/ini-parser library. Choose the download type require. 2. Extract the ZIP file and open the index.php. 3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
chinacn / ini-parser example snippets
composer
$str= <<<'EOT'
[numa]
interleave = all # Interleave
#cpunodebind = 1 # Bind to node 1
#membind = 1
[mysqld]
# Network
port = 3306
socket = /data1/mysql/tmp/mysql.sock
large-pages # Enable large pages
EOT;
$parser = new chinacn\parser\IniParser();
$parser->parse($str);