Code snippet of mouse events using JQuery

Amatya
Posted by Amatya under jQuery category on | Points: 40 | Views : 388
mouseenter()
The function is executed when the mouse pointer enters the HTML element:

Example
$("#DNF").mouseenter(function(){
alert(" Hi DNF members");
});


mouseleave()
The function is executed when the mouse pointer leaves the HTML element:

Example
$("#DNF").mouseleave(function(){
alert("Bye,DNF Members");
});


mousedown()
The function is executed, when the left, middle or right mouse button is pressed down, while the mouse is over the HTML element:

Example
$("#DNF").mousedown(function(){
alert("DNF mouse Down!");
});


mouseup()
The function is executed, when the left, middle or right mouse button is released, while the mouse is over the HTML element:
Example
$("#DNF").mouseup(function(){
alert("DNF Mouse Up!");
});


Thanks
Amatya

Comments or Responses

Login to post response