Mousedown, Mousemove, Mouseover, Mouseout, and Mouseup Events

The Mousedown event occurs when the user press down the mouse button but before the click is complete. The event handler used for this event is onmousedown

The Mousemove event occurs when the user moves the mouse cursor. The event handler used for this event is onmousemove.

The Mouseover event occurs when the user moves the mouse cursor over an element on the web page. The event handler used for this event is onmouseover.

Example:


<a href="http://saigon.ro" onmouseover = "window.alert('Link to another page.');" >Link to another page </a>

The Mouseout event occurs when the user moves the mouse cursor away from an element on the web page. The event handler used for this event is onmouseout.

Example:


<a href="http://saigon.ro" onmouseout = "window.alert('Come back and click me.');" >Link to another page</a>

The Mouseup event occurs when the user releases the mouse button after pressing it down. The event handler used for this event is onmouseup.

Leave a Reply