Hi, Niall,
I see! I do think that it is a bad idea to have the
MultipartRequestWrapper available to the framework prior to its state
being set. And, I assume you will agree on that.
But, this is progress. Ignore my last note.
Jack
On Fri, 25 Feb 2005 09:07:49 -0000, Niall Pemberton
<[EMAIL PROTECTED]> wrote:
> OK I think I have the answer to the confusion, see inline...
>
> ----- Original Message -----
> From: "Dakota Jack" <[EMAIL PROTECTED]>
> Sent: Friday, February 25, 2005 8:38 AM
>
> > Thanks, Niall,
> >
> > I don't know how to approach this without some danger of raising some
> > ill feeling, but I just don't think that MultipartRequestWrapper in
> > Struts either does or can work. You have to parse the request before
> > the wrapper. This is what I have been talking about. I just don't
> > get this architecture. My tests indicate that MultipartRequestWrapper
> > does not return anything from getParameter("whatever") as it is
> > supposed to. And, my understanding of multipart requests tells me
> > that it cannot do so. I think there is a big mistake here or I don't
> > know what is going on.
>
> You're right in what you say and it does happen that way - after the parse,
> but its actually in the Struts implementation of the MultipartHandler.
>
> The default multipart handler for Struts is the
> CommonMultipartRequestHandler - in it's addTextParameter() method it checks
> to see if the Request is a MultipartRequestWrapper. If it is it adds the
> parameter into the Request. Thats how the parameters get into the "wrapped"
> request.
>
> > What I do is create a multipart request handler which utilizes the
> > parsing from the commons DiskUploadUpload parseRequest(...) method.
> > Then I use the handler to populate what I call UploadMultipartRequest.
>
> Since your using Commons fileupload directly, then thats why you're not
> seeing this behaviour.
>
> Niall
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>
--
"You can lead a horse to water but you cannot make it float on its back."
~Dakota Jack~
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]