JS 打印对象的方法
2
3
4
5
6
7
8
|
function writeObj(obj){ var description = "" ; for ( var i in obj){ var property=obj[i]; description+=i+ " = " +property+ "\n" ; } alert(description); } |
博客地址:
http://www.jb51.net/article/73498.htm
本文来自博客园,作者:aspirant,转载请注明原文链接:https://www.cnblogs.com/aspirant/p/5582988.html