HTML and CSS Reference
In-Depth Information
Figure 11-4
javascript event handlers
Category
Event Handler
Occurs
Window and
document event
handlers
onload
The browser has completed loading the document.
onunload
The browser has completed unloading the document.
onerror
An error has occurred in the JavaScript program.
onmove
The user has moved the browser window.
onresize
The user has resized the browser window.
onscroll
The user has moved the scroll bar within the browser
window.
Form event
handlers
onfocus
The user has entered an input field.
onblur
The user has exited an input field.
onchange
The content of an input field has changed.
onselect
The user has selected text within an input or text
area field.
onsubmit
The user has submitted the Web form.
onreset
The user has reset the Web form.
Mouse and key-
board event
handlers
onkeydown
The user has pressed a key.
onkeypress
The user has pressed and released a key.
onclick
The user has clicked the mouse button.
ondblclick
The user has double-clicked the mouse button.
onmousedown
The user has pressed the mouse button.
onmouseup
The user has released the mouse button.
onmousemove
The user has moved the pointer while within the object's
boundaries.
onmouseout
The user has moved the pointer beyond the object's
boundaries.
onmouseover
The user has moved the pointer into the object's
boundaries.
For the clock Web page, you'll trigger the NYClock() function when the page is
initially loaded by a browser by adding the onload event handler attribute to the <body>
tag as follows:
<body onload=”NYClock()”>
You'll make this change to the Web page now.
 
Search WWH ::




Custom Search