Alexis Wilke
Alexis Wilke

Reputation: 20800

Is there any browsers that sends multipart/form-data sub-parts?

I am writing a webserver in C++. I am looking at the POST documentation on w3:

http://www.w3.org/TR/html401/interact/forms.html#h-17.13.4

I see that a POST is supposed to support the full multi-parts scheme: parts and sub-parts (and obviously, sub-sub-parts...) just like for email attachments.

Is there any browser and/or tool that do that on a normal basis? In other words, is it really important for a server to support parts and sub-parts?

The obvious problem with that is the fact that it could mean that two files are uploaded under the same name. That's quite a problem if you ask me. Also, from what I can see in PHP it is not supported at all in that realm. Am I correct?

Upvotes: 0

Views: 60

Answers (1)

Alexis Wilke
Alexis Wilke

Reputation: 20800

Ah! I guess I should have searched a little more and to tell you the truth I had not thought of looking at HTML5 for the answer.

The following paragraph actually includes the answer:

http://www.w3.org/html/wg/drafts/html/master/forms.html#multipart-form-data

Note: In particular, this means that multiple files submitted as part of a single element will result in each file having its own field; the "sets of files" feature ("multipart/mixed") of RFC 2388 is not used.

So it is clear that sub-parts (multipart/mixed) are not to be supported.

Upvotes: 1

Related Questions