When making a Javascript API call, I get my results back like this:
{
"data": {
"2 Broke Girls": {
"air_by_date": 0,
"cache": {
"banner": 1,
"poster": 1
},
"language": "en",
"network": "CBS",
"next_ep_airdate": "2014-02-24",
"paused": 0,
"quality": "HD",
"show_name": "2 Broke Girls",
"status": "Continuing",
"tvdbid": 248741,
"tvrage_id": 28416,
"tvrage_name": "2 Broke Girls"
},
"Alias": {
...
},
"message": "",
"result": "success"
}
}
How can i successfully iterate through all the different shows that are being returned ? I can't use response.data.SHOWNAME because the shows will be changing around alot.
I tried a couple of solutions using $.each() but i didn't really get those to work.
I can get as far as accessing each show title on it's own, but the other data keeps getting returned as being [Object object]
Edit: To make it a little bit clearer, i need access to the field. response.data.RANDOM_TITLE.tvrage_name & response.data.RANDOM_TITLE.status