[jQuery] Re: $.ajax call doesn't complete on 400 bad request response

2010-01-18 Thread anton
I see now I misunderstood the complete functionality of "JSONP", no XMLHttpRequest is made at all, and as a result it's not possible to control HTTP headers. In my case a script like: http://localhost:9998/search/jonas? callback=jsonp1263842210822 "> is injected and and loaded by the browser. I

[jQuery] Re: $.ajax call doesn't complete on 400 bad request response

2010-01-18 Thread anton
A type, sorry, everything works fine without javascript warnings or errors, can seem to get any function to be called after a request which return 400. Just fixed the server so that it returns correct MIME-type "application/javascript" instead of just text for errors, this wasn't the problem thoug

[jQuery] Re: $.ajax call doesn't complete on 400 bad request response

2010-01-18 Thread anton
success function is not called at all when I receiver error code 400: success: function() { alert("success"); }, error: function() { alert("error"); }, complete: function() {