HTML and CSS Reference
In-Depth Information
Figure 13.9 Window was resized manually by the user. The onResize event handler
was triggered.
13.4 Handling Mouse Events
In many previous examples, we've seen uses of the onClick event handler to initiate an
action when a user clicks the mouse in a button or on a link. There are a number of other
events that can be fired due some action of the mouse. When the user moves the mouse
pointer over a link, image, or other object, the onMouseOver event handler is triggered, and
when he or she moves the mouse pointer away from an object, the onMouseOut event is trig-
gered. Table 13.4 lists events that are triggered when mouse movement is detected.
Table 13.4 Mouse Events
Event Handler
When It Is Triggered
onClick
When the mouse is clicked on a link and on form objects like button,
submit.
onDblClick
When the mouse is double-clicked on a link, document, form object,
image.
onMouseDown
When the mouse is pressed on a link, document.
onMouseMove
When the mouse is moved when it is over a link, form object, or most
elements.
onMouseOut
When a mouse is moved out of a link, imagemap.
onMouseOver
When a mouse is moved over or enters a link, imagemap, or most
elements.
onMouseUp
When the mouse is released from a link, document.
 
 
Search WWH ::




Custom Search