How Can We get the Values of the Form without Post in asp.net MVC?
I Have Make a Create Form. & I want the Values in 开发者_如何学GoController how can I get them Without Postback the Whole Page? Any article please help
You could use AJAX to send the form values to a controller action. The jQuery Form plugin is very good for this purpose. The plugin reads all the form values and sends them in an AJAX request to a controller action for processing.
Use javascript to call a web service (i.e ajax). Check out this article for some basics.
Since you're using the "postback" term I think you might be coming from a WebForms background which hides all the HTTP
request-response cycle. POST
s are done on <form>
s, so technically the entire page is not "posted back", but the data from the form in which the pressed resides.
精彩评论