Uploading Images using HTML and ASP: Multipart Form Data | WebReference

Uploading Images using HTML and ASP: Multipart Form Data

Multipart Form Data

Uploading Images using HTML and ASP

In which 'multipart/form-data' rears its ugly head.

What is 'multipart/form-data'?

It's an Internet standard for sending lots of different types of information over the Internet as one bundle. However it doesn't really make much difference what it is because we're only interested in getting the file back out and herein lies Dark Secret Number One.

- ASP doesn't support 'multipart/form-data' as standard!

It is a Shocking Revelation that although Microsoft browsers have supported this format from the moment that Microsoft got interested in the Web, the standard form components they supply for Web serving do not. However help is at hand; there are a vast range of ASP Extensions designed specifically to solve this problem. For instance Software Artisans (https://www.softartisans.com) and more recently Microsoft now produce solutions.

When choosing your solution you should bear in mind that file upload is not as simple as it might seem and herein lies Dark Secret Number Two.

- Some browsers encode files before transmitting them!

A number of browsers on the MacOS upload files encoded as MacBinary (to allow special Mac specific features to be transmitted). While Mac browsers will normally make up only 10% of your visitors, in some picture related industries like publishing you may find that this proportion approaches 100%. If you use a third party component you should ensure that it supports MacBinary.

We will use the solution that comes bundled with ImageGoo as it's no effort and it fulfils all these requirements.


Comments are welcome

Created: Aug. 19, 1999
Revised: Aug. 19, 1999

URL: https://webreference.com/dev/upload/multipartdat.html