From: php dot net at sharpdreams dot com
Operating system: Win32/Apache2
PHP version: 5CVS-2005-08-26 (snap)
PHP Bug Type: PHP options/info functions
Bug description: parse_ini_file does not recognize ${key}
Description:
------------
On the documentaiton page of php.ini, it states:
" Since PHP 5.1.0, it is possible to refer to existing .ini variables from
within .ini files. Example: open_basedir = ${open_basedir} ":/new/dir"."
This does not seem to work in 5.1 for parse_ini_file.
Also, it appears there is no way to reference sections, e.g.,
baz = ${section.foo}
That would be nice. Very nice, in fact (regardless of syntax required).
Reproduce code:
---------------
--- file.ini ---
[Test]
foo = bar
baz = ${foo}
--- test.php ---
<?php
$ini = parse_ini_file( "file.ini", true );
var_dump( $ini );
?>
Expected result:
----------------
array(1) {
["Test"]=>
array(2) {
["foo"]=>
string(3) "bar"
["baz"]=>
string(3) "bar"
}
}
Actual result:
--------------
array(1) {
["Test"]=>
array(2) {
["foo"]=>
string(3) "bar"
["baz"]=>
string(0) ""
}
}
--
Edit bug report at http://bugs.php.net/?id=34274&edit=1
--
Try a CVS snapshot (php4): http://bugs.php.net/fix.php?id=34274&r=trysnapshot4
Try a CVS snapshot (php5.0):
http://bugs.php.net/fix.php?id=34274&r=trysnapshot50
Try a CVS snapshot (php5.1):
http://bugs.php.net/fix.php?id=34274&r=trysnapshot51
Fixed in CVS: http://bugs.php.net/fix.php?id=34274&r=fixedcvs
Fixed in release: http://bugs.php.net/fix.php?id=34274&r=alreadyfixed
Need backtrace: http://bugs.php.net/fix.php?id=34274&r=needtrace
Need Reproduce Script: http://bugs.php.net/fix.php?id=34274&r=needscript
Try newer version: http://bugs.php.net/fix.php?id=34274&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=34274&r=support
Expected behavior: http://bugs.php.net/fix.php?id=34274&r=notwrong
Not enough info:
http://bugs.php.net/fix.php?id=34274&r=notenoughinfo
Submitted twice:
http://bugs.php.net/fix.php?id=34274&r=submittedtwice
register_globals: http://bugs.php.net/fix.php?id=34274&r=globals
PHP 3 support discontinued: http://bugs.php.net/fix.php?id=34274&r=php3
Daylight Savings: http://bugs.php.net/fix.php?id=34274&r=dst
IIS Stability: http://bugs.php.net/fix.php?id=34274&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=34274&r=gnused
Floating point limitations: http://bugs.php.net/fix.php?id=34274&r=float
No Zend Extensions: http://bugs.php.net/fix.php?id=34274&r=nozend
MySQL Configuration Error: http://bugs.php.net/fix.php?id=34274&r=mysqlcfg