Hello, and thanks for reading!
I have an MVC web site that serves up REST-style web services to a jQuery front-end. My question is about the "proper" way of passing certain types of data between the server and the client, especially when it comes to XML or complex .NET data types.
Regarding XML, is there a way to pass "pure" XML, or do you simply always pass XML data as a string? I'm thinking here of the return type on my MVC action... right now I leave the jQuery $.ajax() method at its default content-type, and my MVC method's return type is string, but I wasn't sure if there was a better way.
And then you get into complex .NET data types such as DataSet. Obviouisly jQuery won't be able to process a DataSet object as-is but I wasn't sure if .NET provided a way to translate a DataSet into a more universal datatype, such as XML or JSON.
Any suggestions would be great :)
View Complete Post