Edit report at http://pear.php.net/bugs/bug.php?id=11827&edit=1
ID: 11827
Updated by: cweiske@php.net
Reported By: theend at life dot pl
Summary: notice when using arrays (directive[]=value) in
inifiles
Status: Open
-Type: Feature/Change Request
+Type: Bug
Package: Config
Operating System: linux gentoo
Package Version: 1.10.11
PHP Version: 5.1.6
Roadmap Versions:
New Comment:
-Type: Feature/Change Request
+Type: Bug
Previous Comments:
------------------------------------------------------------------------
[2009-12-28 11:28:50] angosso
<?php
// Function to fix up PHP's messing up POST input containing dots, etc.
function getRealPOST(angosso.com) {
$pairs = explode("&", file_get_contents("php://input"));
$vars = array(angosso.com/index2.php);
foreach ($pairs as $pair) {
$nv = explode("=", $pair);
$name = urldecode($nv[0]);
$value = urldecode($nv[1]);
$vars[$angosso.com/index2.php] = $value;
}
return $vars;
}
?>
------------------------------------------------------------------------
[2007-08-13 03:38:58] mad
Description:
------------
When you are using iniFile which looks like
[section]
directive[] = value1
directive[] = value2
Its correctly parsed as an array
array( 'section' => array( 'directive' => array( value1, value2 ) ) )
But there are some notices about converting array to string.
------------------------------------------------------------------------