I need to parse a simple json response (from my rails app):
[
{
"photo":
{
"updated_at":"2010-10-14T19:12:35Z",
"photo_file_size":206422,
"created_at":"2010-10-14T19:12:01Z"
}
},
{
"photo":
{
"updated_at":"2010-10-16T18:19:38Z",
"photo_file_size":83593,
"created_at":"2010-10-14T19:14:35Z"
}
}
]
i am using:
$(document).ready(function()
{
$.ajax({
type: "GET",
url: "http://myurl...",
dataType: "jsonp",
success: function(data){
console.log(data);
//...
});
}
});
});
firebug console output indicate that the response is ok!
How can i parse each photo_file_size from all photo blocks using function(data)?
any help will be highly appreciated :-)