I have an AJAX call I am using to grab some data from a DB.
$.ajax({
url: URL + '/main/noc/html_forms/query.cfm',
type: 'GET',
dataType: 'json',
data: {
dataset: 'Users'
},
async: false,
timeout: 5000,
cache: false,
success: function(data) {
var result = data.result;
console.log(result);
}
});
I can see from the console that the data is successfully retrieved, except that I can't print this data to a DOM ID element. Even if I do a document.write(result);
the text that is displayed on the screen is
[object Object],[object Object],[object Object]
Again, the data is retrieved successfully because I can see it, I just can't get at it.
I know this is probably a silly question and it'll end up being something I can learn in a 101 class, but can someone explain what is happening here and how I can get at my data?