由于您有一个对象,而不是jQuery包装器,因此需要使用$
.each()的其他变体。
$.each(json, function (key, data) { console.log(key) $.each(data, function (index, data) { console.log('index', data) })})演示:小提琴

由于您有一个对象,而不是jQuery包装器,因此需要使用$
.each()的其他变体。
$.each(json, function (key, data) { console.log(key) $.each(data, function (index, data) { console.log('index', data) })})演示:小提琴