Hello all,
In IE, when an event occurs, as long as it returns true, and
cancelBubble is not set, the event will bubble up through the elements
in the DOM tree.
Though, there is at least one event that does not bubble... the onLoad
event.
For instance:
<BODY onLoad="alert('body onload')">
<IMG src=img.gif onLoad="alert('img onload');">
<SCRIPT>alert("TEST");</SCRIPT>
</BODY>
will show : "img onload", "test", "body onload".
This prooves that the onLoad event did not bubble, even if true is
returned and cancelBubble == false.
Of course, this makes sense. Just because the image has loaded, does
not mean that entire page has loaded.
So, here is my question:
In what other cases are events not bubbled? Is there a pattern? Or is
this the only case?
Thanks,
Brian 1 1660
Brian Genisio wrote: In IE, when an event occurs, as long as it returns true, and cancelBubble is not set, the event will bubble up through the elements in the DOM tree.
Though, there is at least one event that does not bubble... the onLoad event.
For instance: <BODY onLoad="alert('body onload')"> <IMG src=img.gif onLoad="alert('img onload');"> <SCRIPT>alert("TEST");</SCRIPT> </BODY>
will show : "img onload", "test", "body onload".
This prooves that the onLoad event did not bubble, even if true is returned and cancelBubble == false.
Of course, this makes sense. Just because the image has loaded, does not mean that entire page has loaded.
So, here is my question: In what other cases are events not bubbled? Is there a pattern? Or is this the only case?
For IE, check the docs at http://msdn.microsoft.com/library/de...nce/events.asp
they tell you which events bubble.
For DOM compliant browsers, check the W3C DOM Events specification at http://www.w3.org/DOM/, it also lists which events bubble.
--
Martin Honnen http://JavaScript.FAQTs.com/ This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics
by: Vince C. |
last post by:
Hi.
I'd like to trap ADO Recordset object events in my ASP script (either VBS or JS,
no preference). I've tried (in VBS) writing a Sub rs_RecordChangeComplete(
adReason, cRecords, pError,...
|
by: Edward Diener |
last post by:
Is it possible for a derived class to override a property and/or event of
its base class ?
|
by: Sasha |
last post by:
Hi everyone,
Here is my problem:
I have the following classes:
- DataNode - this class is designed to hold some data and will be contained
in a tree like data structure DataTree. When...
|
by: Saso Zagoranski |
last post by:
Hi!
How can I unregister all the events registered to a control?
I have seen a piece of code in another thread, which gets all the registered
handlers for a specific event.
Let's say I have a...
|
by: JPRoot |
last post by:
Hi
I use the following syntax to have events inherited from base to child classes which works nicely (virtual and override keyword on events). But I am wondering if it is a "supported" way of using...
|
by: LP |
last post by:
Hello!
I am still transitioning from VB.NET to C#. I undertand the basic concepts
of Delegates, more so of Events and somewhat understand AsyncCallback
methods. But I need some clarification on...
|
by: Nicky Smith |
last post by:
Hello,
I'm studying a book on VB.net Win apps, and I'm reading a section on
events and delegates and raising events.
Is it just me, or is this not just subs dressed up as something else?
I...
|
by: xoozlez |
last post by:
Hi there,
I have a registration form where I like to filter out the past events of 2007. This is the code I am using :
strSQL = "SELECT EventID, EventName, EventDateBegin, EventDateEnd,...
|
by: swethak |
last post by:
Hi,
I am desiging the calendar application for that purpose i used the below code. But it is for only displys calendar. And also i want to add the events to calendar. In that code displys the...
|
by: Charles Arthur |
last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
|
by: aa123db |
last post by:
Variable and constants
Use var or let for variables and const fror constants.
Var foo ='bar';
Let foo ='bar';const baz ='bar';
Functions
function $name$ ($parameters$) {
}
...
|
by: ryjfgjl |
last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
|
by: ryjfgjl |
last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
|
by: emmanuelkatto |
last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud.
Please let me know.
Thanks!
Emmanuel
|
by: Sonnysonu |
last post by:
This is the data of csv file
1 2 3
1 2 3
1 2 3
1 2 3
2 3
2 3
3
the lengths should be different i have to store the data by column-wise with in the specific length.
suppose the i have to...
|
by: Hystou |
last post by:
There are some requirements for setting up RAID:
1. The motherboard and BIOS support RAID configuration.
2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers,...
| |