I found out that HTML form supports only two enctype types. They are application/x-www-form-urlencoded
and multipart/form-data
. I understand that I use multipart/form-data
when I need to upload a file. When do I use application/x-www-form-urlencoded
? Is it default form enctype?
Yes, it is. Here's a cite from the W3 HTML forms specification:
The default value for this attribute is
"application/x-www-form-urlencoded"
. The value"multipart/form-data"
should be used in combination with theINPUT
element,type="file"
.
The webbrowser will take care about URL encoding automatically.