B
Bender
Hi,
I am wanting to capture an onmousedown event without firing the body tags
onload event.
Also, if anyone could explain why this happens that would be excellent. I
can't see how an onmousedown event could bubble up to an onload event.
NOTE: If you put an alert() statement in the onmousedown event handler the
body onload event doesn't get fired.
Example code:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>
<title>test page</title>
</head>
<body onload="alert('loading page');">
<a href="./page.html" onmousedown="this.style.width = '25%';">test
mouse down</a>
</body>
</html>
I am wanting to capture an onmousedown event without firing the body tags
onload event.
Also, if anyone could explain why this happens that would be excellent. I
can't see how an onmousedown event could bubble up to an onload event.
NOTE: If you put an alert() statement in the onmousedown event handler the
body onload event doesn't get fired.
Example code:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>
<title>test page</title>
</head>
<body onload="alert('loading page');">
<a href="./page.html" onmousedown="this.style.width = '25%';">test
mouse down</a>
</body>
</html>