How to access values of an object without knowing keys in javascript

for(key in obj)
{
 if(obj.hasOwnProperty(key))
 {
  var val = obj[key];
  //do something with the data
 }
}
  

Published by deeps blog

Programmer

Leave a comment

Design a site like this with WordPress.com
Get started