ajax 这样的数据如何遍历,怎么获取到里面的值呀

如题所述

用javascript的for来遍历这个数组即可

for (x in tool){
    document.write(tool[x]['id'] + "<br />");
    document.write(tool[x]['name'] + "<br />");
}

希望能帮助到你

温馨提示:内容为网友见解,仅供参考
无其他回答
相似回答