Rafal Krzewski <[EMAIL PROTECTED]> wrote:
[SNIPPED]
> - User choses files and submits the form.
> - Auto uploader gets the files from the POST stream and stores them in
temporary
> location (an array in memory for small files, temporary file on the disk
for big ones).
> - An action gets FileItems from the Parameter parsers, checks permissions,
file sizes
> (a request exceeding maximum size would be rejected and result with no
FileItems)
> determines file locations (original names are available via
FileItem.getFileName)
> then reads the stream, and stores it to final location, or just ignores
the FileItem
> that will go away (possibly delete temp file) at the end of request
processing.
>
> It's a clear disadvantage that files that you must do an extra read/write of
the file to
> put it in the final location, but this aproach deals consistently with large
requests
> without keeping them in memory as a whole (I believe that memory is the most
valuable
> resource of a busy webserver). It also gives your action access to ordinary
> form fields values before it decides to accept the files or reject them.
This solution works for me.
> Good! I have no experience with writing applets, so I'd be glad if you took
care
> of that. Just read the RFC - creating multipart/form-data and
multipart/mixed
> is easy. I think that you may encounter problems with security here - I
believe that by
> default browsers don't allow applets to read files from the disk, so using
this
> applet would require the user to tweak his configuration.
OK. Will work on it this weekend/beginning next week.
jb
Jeff Brekke
mailto:[EMAIL PROTECTED]
http://sites.netscape.net/ekkerbj
____________________________________________________________________
Get your own FREE, personal Netscape WebMail account today at
http://home.netscape.com/webmail
------------------------------------------------------------
To subscribe: [EMAIL PROTECTED]
To unsubscribe: [EMAIL PROTECTED]
Search: <http://www.mail-archive.com/turbine%40list.working-dogs.com/>
Problems?: [EMAIL PROTECTED]