Model for sending XML to jquery in C#

.net web services can return structs of any simple datatypes as nicely serialized XML and jquery can consume that like this

struct usefullStuff {
string[] commands;
string content;
}

$("commands string", returnedXML).each(function() { eval($(this).text()); });
$("content", returnedXML).each(function() { $("body").append($(this).text()) ; });

0 comments: