views:

34

answers:

2

Which MVC version should I download to use the Ajax functionality in my MVC application? Is it possible with MVC 1.0?

I also want to use Modal Popups in my application.

Thanks Ritz

A: 

Have a look at the NerdDinner Tutorial. The part that talks about Ajax is here: http://nerddinnerbook.s3.amazonaws.com/Part11.htm.

The NerdDinner Tutorial is written around ASP.NET MVC 1.0.

For the Modal Popups. I suggest using a jQuery plugin, like this one: http://dev.iceburg.net/jquery/jqModal/

Robert Harvey
A: 

here is example for you

function someJSFunction() {

    var request = new Sys.Net.WebRequest();
    var someID= (document.getElementById('DOMElementID').value);
    if (someID!= "") {
    var toControler = "/SomeControler/SoomeMethod/" + someID;
    request.set_url(toControler);
    request.set_httpVerb("GET");
    request.add_completed(someOtherJSFunction);
    request.invoke();
    }

}

SonOfOmer