声明:
var points= {};
存:
points.a='123';
points.b ='456';
var p1 = 'c';
points[p1]='789';
结果points= {'a':'123','b':'456','c':'789'};
取:
var d = points['a']; //则d的值就是‘123’
删除:
delete(points['a']);
循环取值:
for(var i in points) { alert(points[i]); }