How would one rewrite this jquery function as regular javascript?
$(document).ready(function() {
$.ajax({
url: 'http://192.168.1.103:8124/',
dataType: "jsonp",
jsonpCallback: "_testcb",
cache: false,
timeout: 5000,
success: function(data) {
$("#test").append(data);
},
error: function(jqXHR, textStatus, errorThrown) {
alert('error ' + textStatus + " " + errorThrown);
}
});
});
Particularly
jsonpCallback: "_testcb",
cache: false,
Original Wrong Question: How does one set the properties of an xmlhttprequest object to recieve JsonP callbacks using regular javascript?
Updated Correct Question: How does one make JsonP Callbacks with "Pure Javascript"?