1
I’m trying to walk a array de objetos with jquery I’m doing so:
$.getJSON('http://localhost:8000/produtos', function(data) {
$(data).each(function (item) {
console.log(item);
$('.product-slider').append(item.NmProduto);
});
console.log(data);
});
In the first console.log(item) is coming out 0 1 2 3.
Already in charge $('.product-slider').append(item.NmProduto); is doing nothing and if I log console on item.NmProduto sai undefined, already in my console.log(data) is coming the right information as in the following print:
I need to set an html in this div with the data coming from json, what is the best way to develop this ?
