struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Bar³omiej Paw³owski <bpawlow...@supermedia.pl>
Subject Re: problem with upload file
Date Fri, 03 Aug 2001 12:50:41 GMT
Thanx, for answer but when I change my form and add
enctype='multipart/form-data' I receive another exception:

Internal Servlet Error:

java.lang.ArrayIndexOutOfBoundsException
 at javax.servlet.http.MultipartHandler.readLine(MultipartHandler.java:139)
 at javax.servlet.http.MultipartHandler.readLine(MultipartHandler.java:103)
 at javax.servlet.http.MultipartHandler.gotoBoundary(MultipartHandler.java:160)
 at javax.servlet.http.MultipartHandler.nextPart(MultipartHandler.java:315)
 at javax.servlet.http.HttpUtils.parseMultiData(HttpUtils.java:204)
 at org.apache.tomcat.util.RequestUtil.readFormData(RequestUtil.java:137)
 at org.apache.tomcat.core.RequestImpl.handleParameters(RequestImpl.java:691)
 at org.apache.tomcat.core.RequestImpl.getParameterValues(RequestImpl.java:259)
 at org.apache.tomcat.core.RequestImpl.getParameter(RequestImpl.java:250)
 at
org.apache.tomcat.facade.HttpServletRequestFacade.getParameter(HttpServletRequestFacade.java:222)

Any idea?

Mark Schenk wrote:

> >
> > Hi
> > I have created multipart form:
> >
> [snipsnip]
> > <br>
> >   <html:form action="/upload" >
> >    File <html:file property="file" />
>
> Hi,
>
>         the problem is, that you didn't create a multipart form! Change your
> form tag to read <html:form action='/upload' enctype='multipart/form-data'>.
> After this the populate will work OK.
>
> Mark
>
> ----------------------------------------------------------------------------
> Mark Schenk                     |       Ceci n'est pas une signature
> Blackboard Project Manager      |
> Delft University of Technology  |E-mail: M.M.A.Schenk@dto.tudelft.nl
> Dept.: DTO                      |Phone:  +31 152785448 (85448)
> Room: LB00.680                  |Fax:    +31 152786359
> ----------------------------------------------------------------------------
> -
>
> >


Mime
View raw message