JSFiddle - React, Tailwind, and code Playground
by geoffreyk
JavaScript
$.ajax({
type: 'get',
url: 'http://openapi.ro/api/companies/123456789.json',
dataType: 'jsonp',
success: function(data) {
alert('success 404');
},
error: function(data) {
alert('fail 404')
}
});
$.ajax({
type: 'get',
url: 'http://widgets.membership.s-msft.com/v1/user/usercard/?id=badID',
dataType: 'jsonp',
success: function(data) {
alert('success 500');
},
error: function(data) {
alert('fail 500')
}
});