Easy Tutorial
❮ Event Trigger Sel Attribute Beginning Value ❯

jQuery mousemove() Method

jQuery Event Methods

Example

Get the position of the mouse pointer on the page:


Definition and Usage

The mousemove event occurs when the mouse pointer is moved within the specified element.

The mousemove() method triggers the mousemove event, or attaches a function to run when a mousemove event occurs.

Note: A mousemove event is fired every time the user moves the mouse by one pixel. Handling all mousemove events can consume system resources. Use this event with caution.


Syntax

Trigger the mousemove event for the selected elements:

Attach a function to the mousemove event:

Parameter Description
function Optional. Specifies the function to run when the mousemove event is triggered.

jQuery Event Methods

❮ Event Trigger Sel Attribute Beginning Value ❯