From:             marco at opus dot ch
Operating system: Windows 2000
PHP version:      4.3.6RC1
PHP Bug Type:     Unknown/Other Function
Bug description:  $_POST and $_FILES empty when upload_max_size exceeded

Description:
------------
I've got a form which uploads a file along with other information
(including and ID that identifies location in the site). When I upload a
file that exceeds the size limits, I get no $_FILES and no $_POST
information. That means if the user chooses a large file, they are
redirected to a 'not allowed to do that here' page instead of a form
error, because the ID is missing and their request can't be validated.



This bug has been documented in the user comments in the documentation,
but is still in the latest release:



http://php.planetmirror.com/manual/en/features.file-upload.common-pitfalls.php



Reproduce code:
---------------
<html>

<body>

<form action="test.html" enctype="multipart/form-data" method="post">

<input type="hidden" name="SID" value="XXX"

<input type="file" name="test">

<input type="submit">

</form>

</html>



<?php



print_r( $_REQUEST );



?>




-- 
Edit bug report at http://bugs.php.net/?id=27844&edit=1
-- 
Try a CVS snapshot (php4):  http://bugs.php.net/fix.php?id=27844&r=trysnapshot4
Try a CVS snapshot (php5):  http://bugs.php.net/fix.php?id=27844&r=trysnapshot5
Fixed in CVS:               http://bugs.php.net/fix.php?id=27844&r=fixedcvs
Fixed in release:           http://bugs.php.net/fix.php?id=27844&r=alreadyfixed
Need backtrace:             http://bugs.php.net/fix.php?id=27844&r=needtrace
Need Reproduce Script:      http://bugs.php.net/fix.php?id=27844&r=needscript
Try newer version:          http://bugs.php.net/fix.php?id=27844&r=oldversion
Not developer issue:        http://bugs.php.net/fix.php?id=27844&r=support
Expected behavior:          http://bugs.php.net/fix.php?id=27844&r=notwrong
Not enough info:            http://bugs.php.net/fix.php?id=27844&r=notenoughinfo
Submitted twice:            http://bugs.php.net/fix.php?id=27844&r=submittedtwice
register_globals:           http://bugs.php.net/fix.php?id=27844&r=globals
PHP 3 support discontinued: http://bugs.php.net/fix.php?id=27844&r=php3
Daylight Savings:           http://bugs.php.net/fix.php?id=27844&r=dst
IIS Stability:              http://bugs.php.net/fix.php?id=27844&r=isapi
Install GNU Sed:            http://bugs.php.net/fix.php?id=27844&r=gnused
Floating point limitations: http://bugs.php.net/fix.php?id=27844&r=float

Reply via email to