I'm going to put this another way: what's the secret with file upload requests? I can't see my file parameter in the request parameters when I submit the form with the multipart-request.

Adam

On 02/29/2004 07:05 PM Adam Hardy wrote:
I use the Commons multipart request handler stuff to set up a DynaActionForm properly for my file upload so:

<form-bean name="linklibImportForm"
type="org.apache.struts.validator.DynaValidatorActionForm">
<form-property name="bookmarksFile"
type="org.apache.struts.upload.CommonsMultipartRequestHandler$CommonsFormFile"/>


</form-bean>

which works fine, but in some circumstances I want to manually create this form, grab the file and save the DynaActionForm (in a filter). Like so:

ActionForm form =
  RequestUtils.createActionForm(request, actionMapping,
  moduleConfig, actionServlet);
form.reset(actionMapping, request);
BeanUtils.populate(form, request.getParameterMap());

But it isn't working. My file comes back as null. Anyone know why or have a solution?



--
struts 1.1 + tomcat 5.0.16 + java 1.4.2
Linux 2.4.20 Debian


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



Reply via email to