Skip to main content

Bug Tracker

Side navigation

#5835 closed bug (fixed)

Opened January 16, 2010 10:35AM UTC

Closed January 23, 2010 04:15PM UTC

Last modified November 17, 2010 02:46AM UTC

Inline script events and "live"

Reported by: superware Owned by: brandon
Priority: major Milestone: 1.4.1
Component: event Version: 1.4
Keywords: inline events live Cc:
Blocked by: Blocking:
Description

Registering a live event somehow affects inline script events, even when the live selector isn't related to the inlined element.

Attachments (2)
  • onclick.html (0.4 KB) - added by superware January 16, 2010 10:36AM UTC.
  • onclick2.html (1.3 KB) - added by iraebrasil January 18, 2010 04:14AM UTC.

    trying to create a testcase for the fix

Change History (5)

Changed January 16, 2010 10:45AM UTC by superware comment:1

Forgot to mention, seems to be an IE6/7 issue.

Changed January 18, 2010 04:13AM UTC by iraebrasil comment:2

I've found the problem.

liveHandler starts with a returnValue of true and in some cases changes it to false. This true value tells IE that it should fire the event, regardless of another handlers (or at least is what I suppose it's happening).

The fix is simple, it's to start the returnValue with undefined, and never change it to true. I've made a commit for that: http://github.com/irae/jquery/commit/6438ab0da979307d8ea0ec5183d6a5e5a57bead8

I was unable to create a test case. Nothing I could do with javascript seems to simulate the bug. Regardless of that, I've tested my fix in firefox, chrome and IE6 and no regressions were made by this simple fix.

I'll attach my debug case with draft for testcase. If anyone figures out how to simulate this with javascript, please, let me know.

Changed January 21, 2010 06:15PM UTC by superware comment:3

iraebrasil, any news? :(

Changed January 23, 2010 04:15PM UTC by john comment:4

priority: criticalmajor
resolution: → fixed
status: newclosed

Changed November 17, 2010 02:46AM UTC by addyosmani comment:5

#5816 is a duplicate of this ticket.