Skip to content

Issue with html form post with enctype=multipart/form-data #472

@laprado

Description

@laprado

Hello,

I was using "Context.Request.Params ['FieldName'] to get content from fields posted via html form with enctype =" multipart / form-data ". This was working before the last update I downloaded.

Additional Information:
** DMVCFramework Server ** build 3.2.2 (nitrogen)
Delphi Sydney 10.4.1
Minimal Reproducible Example: I made a MRE and it is attached. I'm using enctype=multipart/form-data because I have an input type=file on my form and I need to post fields and file together. This input type=file is not needed to reproduce the problem, so I'm not using it on the MRE.
MultiPartFormPost.zip
Work around: I'm using Context.ContentParam('FieldName') to correctly get data from request made by browser.

I dont't know if this is a problem, if not I'm happy to keep using Context.ContentParam('FieldName') or another way that you consider be the correct one. But if you consider this a problem I'd take a look on a commit of 21 Oct 2020 "The TMVCWebRequest.GetParams method failed to look for a field in the…", it's possible this may be the source of this issue.

Thanks for your help and also for this amazing framework.

Metadata

Metadata

Assignees

Labels

acceptedIssue has been accepted and inserted in a future milestone

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions