Hello all,

I've got an HTML form that allows users to upload files. However, I don't
know the directory I want to save the file(s) to until I've parsed some of
the form data (getting things like the userID, calculating next available
fileID, etc.).

I wanted to use Jason Hunter's MultipartRequest class, but it requires a
directory parameter at the start, and I won't have a directory until after
I've parsed the other non-file parameters.

Also, since this is intended for a multiuser system, I don't think I want to
just write everything to /tmp and then use the renameTo() to move it to the
correct place afterwards--another user could upload a file with the same
name immediately afterwards, and couldn't that potentially overwrite the
first file?

Has anyone done something similar before? Can anyone share some pointers or
code examples to handle this?


Thanks in advance!
Eddie


_________________________________________________________________
Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp

___________________________________________________________________________
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff SERVLET-INTEREST".

Archives: http://archives.java.sun.com/archives/servlet-interest.html
Resources: http://java.sun.com/products/servlet/external-resources.html
LISTSERV Help: http://www.lsoft.com/manuals/user/user.html

Reply via email to