CORE ATTRIBUTE:  onmousemove

onmousemove="action"
Available in versions: 4.0
HTML 4.0 tag compatibility: All tags except applet, base, basefront, bdo, br, font, frame, frameset, head, html, iframe, isindex, meta, param, script, style, title
 
The onmousemove core attribute is an event handler that is associated with moving the mouse around while inside a selected HTML tag (element). In other words, the mouse move event occurred while the HTML element was in focus. Every time you move the mouse around the element, the script code of the onmousemove is executed. This script can also call functions or subroutines that contain code that you want to run when this event occurs.
 
The four other similar core attributes are: onmousedown, onmouseout, onmouseover, and onmouseup.
 
In this example, simply move the mouse inside on the button element.
 
Code:
<input type="button" onmousemove="JavaScript: alert( 'onmousemove event' )" value="Move The Mouse Inside This Button!">
 
Output:


Copyright 1999-2001 by Infinite Software Solutions, Inc. All rights reserved.
Trademark Information