File upload with ajax in asp.net mvc

前端 未结 4 1334
遇见更好的自我
遇见更好的自我 2020-12-22 01:23

I know this has been discussed a lot of times.

I basically want the possibility in my view to update a file. This file has to be mapped to the model the controller e

4条回答
  •  执笔经年
    2020-12-22 01:59

    I have made it based on this answer from Demian Flavius: How to do a ASP.NET MVC Ajax form post with multipart/form-data?

    Basically it's the new JavaScript's FormData object that makes it easy for uploading with ajax as in the article your mentioned.

提交回复
热议问题