I have the following code using AJAX to pull JSON data from a few different URLs and I want to store them into separate arrays. Here is a sample:
var var1 = $.ajax({
url: FEED1,
dataType: 'jsonp',
crossDomain: true,
success: function (data) {
if (data) {
ItemAry1 = data.posts;
}
}
});
var var2 = $.ajax({
url: FEED2,
dataType: 'jsonp',
crossDomain: true,
success: function (data) {
if (data) {
ItemAry2 = data.posts;
}
}
});
In my code I have several of these. The issue that each array has the same exact data. Even the FEED1 and FEED2 are urls to different data.