I\'m trying to parse this very long and complicated JSON that foursquare gives me. This is my AJAX request:
$.ajax({
url: \'https://api.foursquare.
The success property of the object in your ajax call just needs function name or an function object. You either give it just the name, like that:
$.ajax({
url: 'https://api.foursquare.com/v2/venues/explore',
dataType: 'json',
data: 'limit=7&ll='+latitude+','+longitude+'&client_id='+client_id+'&client_secret='+client_secret+'',
async: false,
success: getVenues
});
or you do this:
$.ajax({
url: 'https://api.foursquare.com/v2/venues/explore',
dataType: 'json',
data: 'limit=7&ll='+latitude+','+longitude+'&client_id='+client_id+'&client_secret='+client_secret+'',
async: false,
success: function(data) { getVenues(data) }
});