How to use $.ajax to load a local file?
e.g.
$.ajax({
url: "../config.json",
dataType: "json",
success: function(data) {
setting(data);
}
});
function setting(data) {
// some codes that must use "data" to create a page
}
when I put the html and js on service, it will run rightly, but if I run the html file simply, without any service, it's invalid in Firefox and chrome but only valid in IE
I've saw the API about jquery.ajax, and there is a param "isLocal", I don't know why it needs a MAP
! how?