Skip to content

Instantly share code, notes, and snippets.

@arbakker
Created June 17, 2015 13:35
Show Gist options
  • Save arbakker/4226b0f6ad9be3ae003e to your computer and use it in GitHub Desktop.
Save arbakker/4226b0f6ad9be3ae003e to your computer and use it in GitHub Desktop.
Nested ajax
$.getJSON(aurl + "schedule2.cfm?" + "sport=" + sportID, function (data) {
}).success(function (a,b,c) {
var items=a.items;
$.each(items, function (index, value) {
$.getJSON(aurl + "detail.cfm?" + "sport=" + value.id, function (data2) {
}).success(function(a,b,c){
//do stuff
})
})
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment