-3

In a ASP.NET MVC View, what is the syntax to populate a Model using JQuery's $.getJSON or $.ajax?

The MVC code behind is written in C#.

For an MVC View is there something like? -

@model MyModel

$.getJSON('@Url.Action("MyAction","MyController")/', function (dataReturned) { 

    @model = dataReturned  //put the data that is returned into the Model

}
4

1 回答 1

0

MVC 只是一种模式,有无数种方法可以实现它。告诉我们服务器端有哪些语言和库,也许我们可以为您提供帮助。

于 2012-10-12T20:15:40.890 回答