Hi Alexander,

This is what I did after searching the archieves. I'm a little bit confused
with the mime type (shouldn't "multipart/form-data " work for every type of
file? it doesn't work for .jsps). I think I have to search more on this one.

Thanx for the reply,
Konstantina

----- Original Message -----
From: "Jesse Alexander (KADA 12)" <[EMAIL PROTECTED]>
To: "Struts Users Mailing List" <[EMAIL PROTECTED]>
Sent: Thursday, March 14, 2002 9:30 AM
Subject: RE: Downloading files


> Hi,
>
> write an action for the download. This can be a generic action within your
app taking the filename as a parameter.
> In this action:
> - grab request.out    (standard servlet-programming)
> - set the correct mime-type    (standard servlet-programming)
> - read the file    (standard servlet-programming)
> - spit it out on request.out    (standard servlet-programming)
> - return null    (to indicate that the struts-action-servlet has nothing
more to do)
>
> I think in the mailing-list archive should be samples how to return a pdf
or an image that might help you further.
>
> hope this helps
> Alexander
>
> -----Original Message-----
> From: Konstantina Stamopoulou [mailto:[EMAIL PROTECTED]]
> Sent: Montag, 11. Marz 2002 16:03
> To: Struts Users Mailing List
> Subject: Downloading files
>
>
> Hello,
>
> I' m building an application where the user has the options to:
> a.Store his files on the server (upload files)
> b.View the directories and the files he has created on the server side.
These files will be links and when the user "clicks" on one of the files,
the file should open.  Also there will be a link "Download file" for the
file download .
>
> The first part has already been done but I have no idea how to do the
second part.
> Any help, any reference links would be really appriciated since I have
never developed something like that previously.
>
> Many thanx,
> Konstantina
>
>
>
> --
> To unsubscribe, e-mail:
<mailto:[EMAIL PROTECTED]>
> For additional commands, e-mail:
<mailto:[EMAIL PROTECTED]>
>
>


--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to