Here is my
$.ajax({
url: 'http://www.clarkeology.com',
complete: function ( hxr, textStatus ) {
console.log( 'status ' + textStatus );
console.log( 'status ' + hxr.status );
}
});
And here's what my console says:
GET http://www.clarkeology.com/ 200 OK [x] 225ms
status error
status 0
So the console says clarkeology.com returned a 200, but jquery ajax says status is 0. What is going on? jquery api 1 and jquery faq 2 both say it should work.
UPDATE: I am an idiot, I'm trying this cross domain of course it won't work, thanks for the reminder @hpoom :-(
⬅️ Cool Suede reissues :: Free curry and booze! ➡️
Paul Clarkeʼs blog - I live in Hythe, Kent. Married + dad to 2, I am a full-stack web engineer, + I do javascript / nodejs, some ruby, other languages ect ect. I like pubbing, parkrun, eating, home automation + other diy stuff, history, genealogy, TV, squirrels, pirates, lego, + TIME TRAVEL.