Re: New globals for PUT and DELETE
| From: | Sanford Whiteman | Date: | Tue, 28 Oct 2014 18:17:17 +0000 |
| Subject: | Re: New globals for PUT and DELETE | ||
| References: | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-78436@lists.php.net to get a copy of this message | ||
> $_FILES (whose name is already method-agnostic)
The name appears method-agnostic but the implementation obviously
isn't. It works with multipart/form-data, which is tightly coupled
with POST, but which isn't the only way to transfer files, not by a
long shot. If you ignore the HTTP method you're being completely
arbitrary if you still only decode form-data into $_FILES. For
example we PUT and POST bytearray/binary files thousands of times per
day. You can PUT application/xml as a valid file, heck, you can PUT a
tarball, a great way to send multiple files. Would the enhanced
$_FILES be populated in those cases? And if not, why not?
-- S.