Side navigation
#4994 closed feature (worksforme)
Opened July 29, 2009 10:29PM UTC
Closed November 22, 2010 06:16AM UTC
new ajax 'target' option upon which ajaxEvents are triggered, when specified
Reported by: | nbubna | Owned by: | flesler |
---|---|---|---|
Priority: | major | Milestone: | 1.4 |
Component: | ajax | Version: | 1.3.2 |
Keywords: | ajax events load trigger | Cc: | nbubna |
Blocked by: | Blocking: |
Description
Supports a new 'target' option for $.ajax. When specified, all ajax events (ajaxStart and such) are triggered on that, instead of being globally triggered. For $.fn.load calls (and plugins that do similar things), this provides a means to identify the element upon which the ajax action is being done.
See:
http://groups.google.com/group/jquery-dev/browse_thread/thread/caf31f67a3ac159c
Attachments (2)
Change History (4)
Changed September 15, 2009 03:19PM UTC by comment:1
cc: | → nbubna |
---|---|
need: | Review → Patch |
owner: | → flesler |
status: | new → assigned |
type: | enhancement → feature |
Changed September 15, 2009 03:20PM UTC by comment:2
resolution: | → fixed |
---|---|
status: | assigned → closed |
Applied at [6563]
Changed October 08, 2010 03:00PM UTC by comment:3
resolution: | fixed |
---|---|
status: | closed → reopened |
Function $(selector).load() was modified in changeset [6563] in order to use the DOM element as the context of the call to $.ajax.
Looking at jQuery most recent source code, it looks like this change was reverted:
http://github.com/jquery/jquery/blob/master/src/ajax.js#L56
Is there a reason for that?
Changed November 22, 2010 06:16AM UTC by comment:4
resolution: | → worksforme |
---|---|
status: | reopened → closed |
If you need a context for an operation, you have to do it manually through $.ajax
. Automatic context change for the global events is never provided, consistently.