jquery - .each() method not working in IE -
in success method unable loop through xml response.
webmethod is:
public shared function gettypes(byval typeid integer) string dim db new dbmanager dim ds new dataset db.addparameter("@typeid", typeid) ds = db.executedataset("gettypes") ds.tables(0).tablename = "types" dim jsser new system.web.script.serialization.javascriptserializer return jsser.serialize(ds.getxml()) end function
success method is
successmethod: function (response, that) { $(response).find('type').each(function (index) { alert("called"); }) });
xml response is:
<typeid>12</typeid> <recordid>5</recordid> <createdon>2011-04-24t09:00:00+05:00</createdon> <type>here type.</type>
<typeid>22</typeid> <recordid>5</recordid> <createdon>2011-05-08t09:30:00+05:00</createdon> <type>here type.</type>
your xml response contains "type", not contain "type"...
Comments
Post a Comment