|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #15827 posts with enctype=multipart/form-data do not register post vars.
Submitted: 2002-03-02 00:54 UTC Modified: 2002-03-02 06:07 UTC
Avg. Score:5.0 ± 0.0
Reproduced:1 of 1 (100.0%)
Same Version:1 (100.0%)
Same OS:1 (100.0%)
From: scott at datalink dot net dot au Assigned:
Status: Not a bug Package: Variables related
PHP Version: 4.1.2 OS: Redhat 7.0
Private report: No CVE-ID: None
View Add Comment Developer Edit
Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know!
Just going to say 'Me too!'? Don't clutter the database with that please !
Your email address:
Solve the problem:
43 - 41 = ?
Subscribe to this entry?

 [2002-03-02 00:54 UTC] scott at datalink dot net dot au
Forms with an enctype of 'multitype/form-data' do not register the POST variables.

Here's how to reproduce:

----- Short Script Follows -----
<form method=post enctype='multipart/form-data'>
        <input type='text' value='<? print $foo ?>' name='foo'>
        <input type='submit'>
----- End Script -----

Run the script above.   It is simple enough - it has a form that submits to itself, and then displays the HTTP_POST_VARS variable.

When I remove the enctype='multipart/form-data' attribute from the form tag, the script works fine (i.e. the variable 'foo' appears).   The enctype directive appears to surpress the variables.


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2002-03-02 01:04 UTC] scott at datalink dot net dot au
My mistake - after my upgrade (due to the security risk) I didn't re-set the ini file to allow file uploads again.   I guess this directive is there to prevent unauthorised multipart submissions.

For others experiencing this problem, check your ini file and ensure the following line exists:

file_uploads = On
 [2002-03-02 06:07 UTC]
Making this bogus (user error)

PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sun Apr 14 06:01:28 2024 UTC