I am trying to create a very basic Flickr gallery using the Flickr API. What I want to achieve is sorting my pictures by tag. What I am using is jQuery.getJSON() so that I c
I think something like this should do what you want
var imageArray = [];
$.each(data.photoset.photo, function(i, item) {
// if the tag is new, then create an array
if(!imageArray[item.tags])
imageArray[item.tags] = [];
// push the item url onto the tag
imageArray[item.tags].push(item.url_sq);
});