File Upload 2

After the upload form has been submitted to the server we have to get the server to extract the file from the upload. We would expect to be able to do this using plain vanilla ASP. However - Dark Secret Number One - although Microsoft browsers have supported multipart encoding from the moment that Microsoft got interested in the web, the standard form components they supply for web serving do not. Help is at hand; there are a vast range of ASP Extensions designed specifically to solve this problem.

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! Internet Explorer on 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, you should bear in mind your audience (in some picture related industries like publishing you may find that this proportion approaches 100%) and how vocal disgruntled users are likely to be.

A related issue is that you can't really rely on either the file name or the mime type of the file as provided to you. Because of the cross platform nature of the industry a text file may be named 'readme' or 'readme.txt' or even 'readme 10\10\99'. Because the mime type is determined by the browser it could be anything from 'text/plain' to 'application/x-macbinary' to something completely meaningless. You have to make decisions on a case by case basis depending on what you are trying to do.

Review Criteria

So enough of caveats. What are the pros and cons of the different File Upload components? We've reviewed what we consider to be a reasonable cross section of the industry. Bear in mind that these are our opinions on the best packages and that your criteria for selection may be different. Here are the criteria we've used.

Request Objects - you have to remember that Microsoft really should have supported multipart encoding within their Request and Form ASP objects. Given that they haven't, any replacement should be as similar as possible to the originals, just adding in the new file fields in a sensible way. We've been very fussy about this issue because often it's the smallest differences that lead to confusion. There are some surprisingly complicated parts to these seemingly simple objects and as you can see from the table below, many developers cut corners. To allow you to see how the different objects perform the same function we've put together a simple code section for each of the packages.

Upload Facilities - the new file fields in the objects should be added in logically and should offer certain features. These should include support for MacBinary, the ability to limit the sizes of uploaded files, methods for saving the uploaded file data or putting it into a database.

Documentation - this includes installation, documentation, sample code and general finish. Is using the components a pleasure or is doing the simplest little thing a real pain?

Support - we sent each of the companies involved a simple question 'Why do files coming uploaded from my Mac arrive corrupted?' (see top of page for answer). We gave marks for promptness and correctness.

Review Detail

These reviews have been removed because they are out of date.