1๐
โ
If you respond with a json dump, then you can process it in js like this:
$.get(targetURL).done(function(data) {
$.each(data, function(i,d) {
$("#results").append($("<tr><td>" + d.name + "</td></tr>"));
});
});
Or like this:
$.get(targetURL).done(function(data) {
$("#results").append(data.map(function(i,d) {
return $("<tr><td>" + d.name + "</td></tr>");
}));
});
๐ค000
Source:stackexchange.com