for(var key in result) { var value = result[key]; if(typeof value == 'object') { if(value instanceof Array) { // an array. loop through children for(var i = 0; i < value.length; i++) { var item = value[i]; } } else { // complex object, not array. inner for loop on keys? } } else { // regular string/number etc. just print out value? }}


