I have a web method in ASP.net which it's output is an ArrayList and read cities from databse. this web method is called using jquery.
$.ajax(
{ url: "../AjaxServices/StateCity.asmx/showcity",
contentType: "application/json; charset=utf-8",
dataType: "json",
type: "POST",
data: '{s: ' + $('#<%=DpState.ClientID%>').val() + '}',
success: function(data) {
}
I wanna know how to loop through data, because the data is object.
I knew about
jQuery.each( collection, callback(indexInArray, valueOfElement) )
but doesn't work
dataparameter in Firebug.