首页 > 代码库 > js打印对象数组信息

js打印对象数组信息

function writeObj(obj){ 
 var description = ""; 
 for(var i in obj){ 
 var property=obj[i]; 
 description+=i+" = "+property+"\n"; 
 } 
 alert(description); 
}

 

js打印对象数组信息