$.each(data, function(index, item){ var name; for(name in item){ console.log(name + " = " + item[name]);} });
On Wed, May 20, 2009 at 5:51 AM, Massimiliano Marini <m...@linuxtime.it>wrote: > > Hi Charlie, > > > I'm not good at explaining the exact terms javascript definitions for > > "value and key" but they are javascript identifiers? change it to > > what their values are in the array, works great > > what I want to do is to print the "name" and the "value" of a json > object without knowing what the object has inside. > > The only thing I know is that inside the json object there are only > [{name:value,name:value,name:value}], the object is not fixed lenght > and the name:value are not always the same. > > Is it possible? > > -- > Massimiliano Marini <m...@linuxtime.it> > -- Christopher Thatcher