Asp.net mvc Download ajax File

Hi, I got a mvc form with file upload function. Ive got an action that takes a file and extracts thumbnails from it, after which the user can select the image and then proceed to submit the form. How can I publish the source file using ajax, given this, this is not the final presentation of the form, and I want to save user input. those. no postback thanks

+3
source share
2 answers

I am using the ajaxupload plugin for jQuery. The site provides many code examples. On the site:

[The] plugin creates an invisible file entry on top of the button that you provide, so when the user clicks on your button, a window for selecting a normal file is displayed. And after the user selects the file, the plugin submits the form containing the input file in the iframe. So this is not a true ajax download, but brings the same user interface.

+2
source

Browsers do not allow downloading files via ajax. Still a few good workarounds .

0
source

Source: https://habr.com/ru/post/1746627/


All Articles