<...">

Empty request. Files Downloading MVC 3 File

This is my markup:

<form action="/Customer/Create" enctype="multipart/form-data" method="post">
    <input id="file" type="file" style="width:300px" />
    <input type="submit" id="btnSubmit" value="Add Image to S3" />
</form>

When I execute the Create action, the Request.Files are empty. I searched and searched, and all the advice seems to be that enctype is set to "multipart / form-data", which I already set. Any other ideas?

+5
source share
1 answer

Try adding the attribute nameto input. I do not think that elements of anonymous form are generally published.

+11
source

All Articles