[EMAIL PROTECTED] wrote:
> 
> Hi,
> I want to use turbine to allow users to upload a file to the server and
> make this available for other users to download.
> 
> I last time I looked at Turbine it used the O'Reilly uploader, and I could
> store my files on the filesystem and users could download them OK.
> 
>  I'm having difficulty understanding how the new system  works/ is
> configured.
> 
> Could someone give me a quick explanation as to how it works and should be
> configured to enable me to acheive the aims mentioned above?

I'm the person who performed the code reorganization so, I'll do my best to
help you out.

There are multiple implementations of upload service avaliable, including 
the O'Reily uploader. You need the following settings in TurbineResources.properties
to use it:

services.TurbineUploadService.classame=org.apache.turbine.services.upload.OReillyUploadService
# the UploadService implementation developed from old 
org.apache.turbine.util.upload.OReillyUploader

services.TurbineUploadService.automatic=false
# you want your files to be pickedup by the UpladFile action

services.TurbineUploadService.repository=/somepath/
# set the path where you want your files here

services.TurbineUploadService.size.max=1048576
# set the maximum size of the request to be accepted in bytes

Use org.apache.turbine.samples.actions.UploadFile to perform the upload.

I expect that you should be able to upgrade your system smoothly. If you have any 
problems, you
can contact me be private email.
 
> What does this do :
> 
> # This is the file server where files will be uploaded for
> # mulipart/form-data requests
> # Default: none
> #file.server=

Frankly, I have no idea. I have good knowledge of file upload subsystem,
and I haven't encoutered any references to that configuration value in
the code. I was wondering what could it be, and some grepintg revealed
that this config key is referenced int the e-mail subsytem. Strange, eh?
Maybe I just haven't been around long enough...
 
> Can I no longer just upload to my servers file system?

You can upload the files to the filesystem like you did before.
 
> Also how do I download a file using the new system?
 
The uploading code is not related to downloading. If you set your 
repository directory inside your webapp dir, but outside WEB-INF,
your files will be served by Tomcat without any further intervetion
(you must provide URLs for them to the user somehow though). Otherwise
you need to read them and feed them to the browser.

Rafal


------------------------------------------------------------
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