On 8/23/01 10:28 AM, "Gunter Miessbrandt" <[EMAIL PROTECTED]> wrote:

> Hi,
> I have problems with UploadService.
> When I try to upload a file FileItem
> often writes 0 bytes long file. The upload work fine as long as the file is
> a jpg-graphic. With other extensions it doesn?t work. Sometimes the
> jpg-files are only half loaded.
> My Turbine Version is 2.1.
> 
> Here's the code that I use to upload the file:
> FileItem fileItem =
> data.getParameters().getFileItem("file");
> fileItem.write(TurbineServlet.getRealPath("uploaded.file"));
> 
> The form in the template file is with "enctype" set to
> "multipart/form-data".
> I have searched the archives but found no answer.

If you always want the files to be saved to disk than set

services.UploadService.automatic = true
services.UploadService.size.threshold = 0

Do you have these values set?

 
> Thanks in advance for any help I get!
> Gunter Miessbrandt
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]

-- 

jvz.

Jason van Zyl

http://tambora.zenplex.org
http://jakarta.apache.org/turbine
http://jakarta.apache.org/velocity
http://jakarta.apache.org/alexandria
http://jakarta.apache.org/commons



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

Reply via email to