Ticket #12290 (closed bug: invalid)
$.ajaxSetup "success" global event bug against "complete" and other correct global events(not repeated)
| Reported by: | abbasali hashemian (alix) <alixniv@…> | Owned by: | |
|---|---|---|---|
| Priority: | low | Milestone: | None |
| Component: | ajax | Version: | 1.8.0 |
| Keywords: | dbr | Cc: | |
| Blocking: | Blocked by: |
Description
$.ajaxSetup({
type : 'POST',
// data : {},
beforeSend : function ( XHR ){},
complete : function ( XHR ){
alert(0) //OK
},
success : function(data){
alert(1) //BOOM
},
error : function ( XHR ){
AJAX_Err(XHR)
}
If we use $(...).load or $.post later "complete" will work but "success" will not.
more information :
browser : firefox 10.0.2 - OS : win7(nothing is related to OS)
Bug accidents : jQ1.4.2 - jQ1.7.1(repeated) - jQ1.8.0(yes it's here again)
Bug accident env : either with my complex and reduced code and jQGrid plugin also(complete worked success not). Excuse me, for a long term I resolved it for myself and for now yes I'm using complete instead of success but for other friends it may be a vital problem to have an event after success ajax and before injecting html data.
THANK YOU
Change History
comment:1 Changed 9 months ago by sindresorhus
- Priority changed from undecided to low
- Component changed from unfiled to ajax
comment:2 follow-up: ↓ 3 Changed 9 months ago by alix
Yes, I'll try to post a simple test fiddle code. However If "dmethvin" lets us and doesn't close this Ticket as invalid like this : http://bugs.jquery.com/ticket/12288 "live / delegate filter :enabled bug"
comment:3 in reply to: ↑ 2 Changed 9 months ago by ajpiano
"dmethvin" is Dave Methvin and he's the lead developer for jQuery Core and the development lead for the jQuery Project. If you have a problem with him attentively closing bugs that are indeed invalid shortly after filing them, well, you should probably find a way to not have that problem any more, because it's actually a good thing.
comment:4 Changed 9 months ago by alix
Yep
Thank you "ajpiano" for advising me respectfully
And also you "sindresorhus", Thank you for consulting
However I think closing of that bug was not attentively because I told "live / delegate" not exactly "live"(as a deprecated method) so obviously the actual problem is probably in another point or core
Actually that bug took a lot of my time to find the sub-bugs and finally I decided to let other friends to know that.
I have no problem with "Mr. Dave Methvin" but if jQuery is a free opensource js+dom library it doesn't mean caring customers is not important. I came to help but I had to spend a lot of time on jsFiddle and on jQuery Bug Tracker and finally I saw my post was "CLOSED/INVALID BUG". I think it is not respectful.
So if jQuery has no time to spend for friendly bug reports I have no more time spend also. BYE
ALIX
Master PHP / ASP.net developer and CEO
Tondarweb
Please follow the bug reporting guidlines and use jsFiddle when providing test cases and demonstrations instead of pasting the code in the ticket.

Can you post a testcase on jsfiddle demonstrating the issue?
See the ajax docs:
Does the same thing happen with .always() ?