Example of multipart/form-data

EDIT: I am maintaining a similar, but more in-depth answer at: https://stackoverflow.com/a/28380690/895245 To see exactly what is happening, use nc -l or an ECHO server and an user agent like a browser or cURL. Save the form to an .html file: <form action=”http://localhost:8000″ method=”post” enctype=”multipart/form-data”> <p><input type=”text” name=”text” value=”text default”> <p><input type=”file” name=”file1″> <p><input type=”file” … Read more