Bug Tracker

Modify

Ticket #5576 (closed bug: invalid)

Opened 4 years ago

Last modified 4 years ago

Live event listener fails on first event type

Reported by: matas Owned by: brandon
Priority: major Milestone: 1.4
Component: event Version: 1.3.2
Keywords: Cc:
Blocking: Blocked by:

Description

The first event type in the multiple event definition like 'onFirst' here:

$(document).live('onFirst onSecond onThird', function(event) {

alert('Live: multi event type worked:' + event.type);

});

will never be called.

the 'bind' version will work as expected:

$(document).bind('onFirst onSecond onThird', function(event) {

alert('Bind: multi event type worked:' + event.type);

});

a working example:  http://jsbin.com/elenu

reproducable in FF in Safari

Change History

comment:1 Changed 4 years ago by dmethvin

  • Status changed from new to closed
  • Resolution set to invalid

You are trying something that is not supported:

 http://docs.jquery.com/Events/live#typefn

"Unlike .bind(), only a single event can be bound in each call to the .live() method."

Please follow the  bug reporting guidlines and use  jsFiddle when providing test cases and demonstrations instead of pasting the code in the ticket.

View

Add a comment

Modify Ticket

Action
as closed
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.