Using Event Bubbling with the onClick Event : HTML Body Event : HTML JAVASCRIPT DHTML TUTORIALS


JAVASCRIPT DHTML TUTORIALS » HTML » HTML Body Event »

 

Using Event Bubbling with the onClick Event



<HTML>
<HEAD>
<TITLE>Using Event Bubbling</TITLE>
<SCRIPT><!--
function buttonClickHandler() {
 alert("The onClick event was handled by buttonClickHandler()")
}
function formClickHandler() {
 alert("The onClick event was handled by formClickHandler()")
}
function documentClickHandler() {
 alert("The onClick event was handled by documentClickHandler()")
}
//--></SCRIPT>
</HEAD>
<BODY ONCLICK="documentClickHandler()">
<H1>Using Event Bubbling</H1>
<FORM ONCLICK="formClickHandler()">
<INPUT TYPE="BUTTON" ONCLICK="buttonClickHandler()" VALUE="Click here!">
</FORM>
</BODY>
</HTML>
           
       



-

Leave a Comment / Note


 
Verification is used to prevent unwanted posts (spam). .

Follow Navioo On Twitter

JAVASCRIPT DHTML TUTORIALS

 Navioo HTML
» HTML Body Event