43 if ( file_exists( $this->_mFilePath ) ) {
45 foreach ( explode(
"\n", file_get_contents( $this->_mFilePath ) ) as $line ) {
47 if ( preg_match(
'/^\s*([;#]|\/\/)/', $line ) ) {
51 $line = preg_replace(
'/\r/',
'', $line );
53 if ( preg_match(
'/\[(.*)\]/', $line, $str ) ) {
54 if (
true === $this->_mSectionFlag ) {
56 $this->_mConfig[ $key ] = [];
59 elseif ( preg_match(
'/^(.*)=(.*)$/', $line, $str ) ) {
62 if ( preg_match(
'/^"(.*)"$/', $val, $body ) || preg_match(
'/^\'(.*)\'$/', $val, $body ) ) {
66 if (
true === $this->_mSectionFlag ) {
67 $this->_mConfig[ $key ][ $name ] = $val;
69 $this->_mConfig[ $name ] = $val;