Last post Feb 25, 2012 01:32 PM by francesco abbruzzese
Aug 23, 2011 01:33 PM|shapper|LINK
I have a MVC Application where I would like to implement some Ajax functionality.
For example, create a post, update a post, refresh a list and sort it, add an item, etc.
I think this can be done using:
- JQuery + JSonResult
What is, in our opinion, the best solution for MVC 3?
I have been looking in all this options and even others but I can't decide which one to choose.
And will MVC 4 include something to make this easier?
Aug 23, 2011 01:48 PM|raduenuca|LINK
I have worked with JQuery + JSonResult and Knockout.js. For simple views you'll be fine with just JQuery + JSonResult but for complex views with lot of interaction the Knockout.js will help a lot.
Here you can find a sample of how to perform cascading on dropdownlists
Aug 25, 2011 07:17 AM|imran_ku07|LINK
Also see the formar ASP.NET MVC team member post.
Aug 25, 2011 07:28 AM|lovedota21|LINK
Knockout & Mvc is better, I am using them to handle JSON, You can do everything with Knockout Drag & Drop, Ajax Paging...
Try it !
Aug 25, 2011 04:22 PM|shapper|LINK
I am going to try it.
Feb 24, 2012 06:31 PM|mastefano1964|LINK
or a linq provider that implement IQueryable. On the server is used "Dynamic Expressions and Queries in LINQ by Microsoft" to compose dynamically your query. There is also support for knockout.js, so you can use in your pages the MVVM pattern. In this way
you can create a MVC jquery knockout.js grid with filter, paging and sort functions. There is also support for mvc3 unobtrusive jquery validation (it will be used some custom mvc htmlhelper). There is also support for jquery mobile, so you can create a datasource
for a jquery mobile apps.
Feb 25, 2012 01:32 PM|francesco abbruzzese|LINK
If you are going to use knockout js. give a look to Mvc Controls Toolkit
convention used by the default model binder, and the client viewmodel side is automatically serialized and sent to the client...and on post deserialize and put in the right place within the server side ViewModel. You can write knockout powered views as normal
razor views forgetting about bindings and client model handling...everything is handled auomatically by the framework...You have just to add the client side javascrit SPECIFIC for your application all "Hard Plumbing" is handled automatically.