| Author |
JQuery .on(): Delegating to an enclosing DIV
|
K Mansoor
Ranch Hand
Joined: Jan 10, 2006
Posts: 52
|
|
Can a <DIV> element be used to delegate events bound to elements which will come into existence in the future?
Can I do something like this? please keep in mind at the execution of this code, the form and it's children (the button with id='some-button-id') does not exist.
This is not working for me, however, the following does work:
|
 |
Bear Bibeault
Author and ninkuma
Marshal
Joined: Jan 10, 2002
Posts: 56191
|
|
|
Should work. Please post an SSCCE (Short Self-Contained Correct Example)
|
[Smart Questions] [JSP FAQ] [Books by Bear] [Bear's FrontMan] [About Bear]
|
 |
K Mansoor
Ranch Hand
Joined: Jan 10, 2006
Posts: 52
|
|
As I started to construct the example. The code started to work. Browser caching? not sure.
Thank you.
|
 |
Bear Bibeault
Author and ninkuma
Marshal
Joined: Jan 10, 2002
Posts: 56191
|
|
If only all problems resolved themselves so easily!
|
 |
 |
|
|
subject: JQuery .on(): Delegating to an enclosing DIV
|
|
|