Javatpoint Logo
Javatpoint Logo

jQuery mouseenter()

The mouseenter() method adds an event handler function to an HTML element. This function is executed, when the mouse pointer enters the HTML element.

When you enter your mouse cursor over the selected element, it triggers the mouseenter event and once the mouseenter event is occurred, it executes the mouseenter() method to attach the event handler function to run.

This event is generally used together with mouseleave() event.

Syntax:

It triggers the mouseenter event for selected elements.

It adds a function to the mouseenter event.

Parameters of jQuery mouseenter() event

Parameter Description
Function It is an optional parameter. It executes itself when the mouseenter event is triggered.

Example of jQuery mouseenter() event

Let's take an example to demonstrate jQuery mouseenter() event.

Test it Now

Output:

Enter this heading.


jQuery mouseenter() event example 2

Let's see another example of jQuery mouseenter() event.

Test it Now

Output:

Move your mouse cursor over this statement.





Let's Work Together!

Javatpoint is passionate to offer better content to the world. Please mail your contribution to contribute@javatpoint.com. We will show your name and create your user profile. You can contribute the following things:
  • Article on Any Topic (which is not available on Javatpoint)
  • Your Interview Experience on Company
  • Company Interview Questions with Answers
  • Recruitment Process of Company
  • Programs, and Algorithm
  • Videos
  • Test Paper
  • Improve Article

Please Share

facebook twitter google plus pinterest

Learn Latest Tutorials