3

Hi I was just wondering if its possible to do an ajax post a file in asp.net mvc, basically i have a form with two buttons, one of the buttons extracts images for the selected document and displays them for the user to choose thumbnails for the document he is about to upload. The usee then fills out the rest of the form and then saves the document.

With the image extraction, I was wondering if it was possible to do that as an ajax post. The other submit button can work as a normal http post Thanks

4 Answers 4

3

You may take a look at the jQuery Form plugin which allows you to ajaxify forms that contain file inputs.

Sign up to request clarification or add additional context in comments.

Comments

3

Using web controls under MVC application is a real mess. I suggest you to try this sample project. ( Also, there are many useful MVC samples in there )

Comments

0

there sure is. If you use the ajaxForm plugin you should be able to do it no problem. I've implemented this on my site and it works very well. Here's and example: http://jquery.malsup.com/form/#file-upload

1 Comment

I have tried it but the it does not postback or do an ajax post on my form
0

Flash upload works the best if its an option as it gives you more flexibility on the UI side. There are a lot of jQuery plugins that will do this. Uploadify is the one I like best. If you can't use Flash, check out this post on how to do jQuery file uploads in asp.net mvc without flash, which uses the jQuery form plugin mentioned previously.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.