Sean Allen wrote:

> I cannot seem to be able to figure out how to get that information ,I
> know I have to get the filename as inserted into the form(minus the path
> of course) , but the example File Upload action does not deal with this
> at all, also, if I wanted to save the file with a predetermined filename
> (i.e. image1.jpg) how would I manipulate this before passing to the
> TurbineUpload.parseRequest(req, data, path).

Use automatic uploading. Then in your action you can manipulate the
FileItem
object that you'll find in the parameter parser. All the information
about
the uploaded file available to Turbine is stored therein.
You can read the contents of the file from a stream and write them to
the
location you want (posibly based on uploaded file's original name), or 
optionaly if the file content's are stored in a temporary file, just
grab
the File object for the temp location and rename() it to where you need
it.

Please take a look at the FileItem javadocs. If you have further
questions,
don't heistate to write.

Rafal

--
Rafal Krzewski
Senior Internet Developer
mailto:[EMAIL PROTECTED]
+48 22 8534830 http://e-point.pl


------------------------------------------------------------
To subscribe:        [EMAIL PROTECTED]
To unsubscribe:      [EMAIL PROTECTED]
Search: <http://www.mail-archive.com/turbine%40list.working-dogs.com/>
Problems?:           [EMAIL PROTECTED]

Reply via email to