|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #37276 problems witch $_POST array
Submitted: 2006-05-02 14:17 UTC Modified: 2006-05-12 13:04 UTC
Avg. Score:4.8 ± 0.6
Reproduced:23 of 24 (95.8%)
Same Version:21 (91.3%)
Same OS:9 (39.1%)
From: puovils at gmail dot com Assigned: dmitry
Status: Closed Package: *General Issues
PHP Version: 5.1.3 OS:
Private report: No CVE-ID:
 [2006-05-02 14:17 UTC] puovils at gmail dot com
problems witch $_POST array

Reproduce code:
echo "<pre>";
echo "</pre>";
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<form method="post" action="" enctype="multipart/form-data">
<input type="text" name="masivasid[id_1]" value="Nzzz1"/><br/>
<input type="text" name="masivasid[id_2]" value="Nzzz2"/><br/>
<input type="submit"/>

Expected result:
    [masivasid] => Array
            [id_1] => Nzzz1
            [id_2] => Nzzz2


Actual result:
    [masivasid] => Array
            [id_1] => Nzzz1
            [id_2] => Array
                    [id_1] => Nzzz2




Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2006-05-02 21:25 UTC] mjackson at datahost dot com
To add to puovils at gmail dot com's comments, you get the expected results if the form is submitted via GET.
 [2006-05-03 02:12 UTC] eric dot caron at gmail dot com
I really don't mean to be "chicken little", but isn't this serious enough that it warrants and/or a recall of 5.1.3?

Its happening on all the linux boxes I've tried.
 [2006-05-03 09:17 UTC] zc dot job at gmx dot net
i also get the problem on a fedora core 5/php 5.1.3,
the problem dosn't apear if the form is submit via GET!

is there a bug fix?

 [2006-05-03 10:14 UTC] kervala at jpopdb dot net
I also have the same problem on a LFS Linux with PHP 5.1.3 and Apache 2.2.2, all forms of my sites are not working anymore due to this critical bug...

My HTML code :
<input class="forminputtext" type="text" name="tab[38][partenaire_responsable]" id="tab[38][partenaire_responsable]" value="Correct Name" maxlength="100" size="69" />

$_POST data returned by this form :
[partenaire_responsable] => Array
   [tion] => Correct Name

instead of :
[partenaire_responsable] => Correct Name

I think the "tion" index comes from a previous field named "partenaire_description" so it could be possible that previous field name was incorrectly deleted from memory.
 [2006-05-03 10:16 UTC] kervala at jpopdb dot net
I forgot to add that phpMyAdmin isn't working anymore and put "Array" strings almost everywhere instead of correct datas...
 [2006-05-03 10:30 UTC] judas dot iscariote at gmail dot com
Yes, there is something very wrong, I have experienced this problem with phpmyadmin but neglected to report here :-(
 [2006-05-03 10:34 UTC] daffy at evil dot lt
Concerning phpMyAdmin :

The same problem exists on win32 too.
 [2006-05-03 11:05 UTC] kervala at jpopdb dot net
I just looked in PHP code and I think problem is in "php_register_variable_ex" function in "main/php_variables.c" file.
 [2006-05-03 11:48 UTC]
Fixed in CVS HEAD and PHP_5_1.
PHP Copyright © 2001-2015 The PHP Group
All rights reserved.
Last updated: Tue Dec 01 07:01:35 2015 UTC