ID: 18881
Comment by: destes at ix dot netcom dot com
Reported By: martijn at sheeponfire dot nl
Status: Open
Bug Type: Feature/Change Request
Operating System: linux, windows
PHP Version: 4.2.2
New Comment:
You are right that it's a more logical structure, but it would be a
royal pain in the posterior to change it, because scripts which depend
on the current structure would be invalidated. As much as it'd be nice
to change it, I don't think the return is worth the investment in
hassling users when they upgrade.
Previous Comments:
------------------------------------------------------------------------
[2002-08-13 09:33:31] martijn at sheeponfire dot nl
when you submit files with a form like this:
<form method="post" enctype="multipart/form-data">
<input type="file" name="File[one][two][]"><br>
<input type="file" name="File[one][two][]"><br>
<input type="submit" value="go">
</form>
the superglobal $_FILES looks like this:
Array
(
[File] => Array
(
[name] => Array
(
[one] => Array
(
[two] => Array
(
[0] => empty.gif
[1] => header.gif
)
)
)
[type] => Array
(
[one] => Array
(
[two] => Array
(
[0] => image/gif
[1] => image/gif
)
)
)
[tmp_name] => Array
(
[one] => Array
(
[two] => Array
(
[0] => /tmp/phpuploads/php2ocF9K
[1] => /tmp/phpuploads/phpmUbo1l
)
)
)
[error] => Array
(
[one] => Array
(
[two] => Array
(
[0] => 0
[1] => 0
)
)
)
[size] => Array
(
[one] => Array
(
[two] => Array
(
[0] => 43
[1] => 5128
)
)
)
)
)
Personally I think this is not very logical, I would prefer something
like this:
Array
(
[File] => Array
(
[one] => Array
(
[two] => Array
(
[0] => Array
(
[name] => empty.gif
[type] => image/gif
[tmp_name] => /tmp/phpuploads/php2ocF9K
[error] => 0
[size] => 43
)
[1] => Array
(
[name] => header.gif
[type] => image/gif
[tmp_name] => /tmp/phpuploads/phpmUbo1l
[error] => 0
[size] => 5128
)
)
)
)
)
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=18881&edit=1