[jQuery] Re: HowTo: Trigger error callback in ajax request

2008-12-17 Thread Rob Wilkerson
On Dec 17, 9:57 am, MorningZ wrote: > "Is it a non-200 status code" > > I can't say it's 100% of the time, but in my code it seems to be the > case Ding, ding, ding. Looks like that's it. In my PHP script, this is what I did to test... try { throw new Exception ( 'Something I made up' ); }

[jQuery] Re: HowTo: Trigger error callback in ajax request

2008-12-17 Thread MorningZ
"Is it a non-200 status code" I can't say it's 100% of the time, but in my code it seems to be the case this code: function reqJSON(url, params, success, error) { var CallParams = {}; CallParams.type = params.Method || "POST"; CallParams.url = url; CallParams.processData = true;

[jQuery] Re: HowTo: Trigger error callback in ajax request

2008-12-17 Thread Andy Matthews
I think the problem is that you're expecting a different sort of error than what the AJAX call is expecting. That method only looks for an error in what it's trying to do. The server process is solely separated from the JS process. You could check for a string of "error" on success, then pass tha

[jQuery] Re: HowTo: Trigger error callback in ajax request

2008-12-17 Thread Andy Matthews
Have you tried 'throw' yet? http://www.w3schools.com/js/js_throw.asp andy -Original Message- From: jquery-en@googlegroups.com [mailto:jquery...@googlegroups.com] On Behalf Of Rob Wilkerson Sent: Wednesday, December 17, 2008 8:26 AM To: jQuery (English) Subject: [jQuery] HowTo: Trigge