Doc #70501 [Fbk->Opn]: MAX_FILE_SIZE docs incorrect
| From: | olafvdspek at gmail dot com | Date: | Tue, 15 Sep 2015 11:57:03 +0000 |
| Subject: | Doc #70501 [Fbk->Opn]: MAX_FILE_SIZE docs incorrect | ||
| References: | 1 | Groups: | php.doc.bugs |
| Request: | Send a blank email to doc-bugs+get-12755@lists.php.net to get a copy of this message | ||
Edit report at https://bugs.php.net/bug.php?id=70501&edit=1
ID: 70501
User updated by: olafvdspek at gmail dot com
Reported by: olafvdspek at gmail dot com
Summary: MAX_FILE_SIZE docs incorrect
-Status: Feedback
+Status: Open
Type: Documentation Problem
Package: Documentation problem
Operating System: *
PHP Version: 5.6.13
Block user comment: N
Private report: N
New Comment:
The value isn't ignored, but it's checked AFTER the entire file was uploaded.
Previous Comments:
------------------------------------------------------------------------
[2015-09-15 11:54:14] requinix@php.net
The sentence before that is
> The MAX_FILE_SIZE hidden field (measured in bytes) must precede the file input
> field, and its value is the maximum filesize accepted by PHP.
If you have a repro script that has this field appearing before the file input and the value is
still ignored, please share it so the problem can be fixed.
------------------------------------------------------------------------
[2015-09-15 11:06:53] olafvdspek at gmail dot com
Description:
------------
> This form element should always be used as it saves users the trouble of waiting for a big file
> being transferred only to find that it was too large and the transfer failed.
As far as I know this bit is incorrect. It does NOT avoid a too-large file from being uploaded as
the value is only checked AFTER the file was uploaded completely.
http://php.net/manual/en/features.file-upload.post-method.php
IMO MAX_FILE_SIZE is useless and should be dropped entirely.
Test script:
---------------
-
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=70501&edit=1