Hiding paragraph using mouse leave function – jquery
Hiding paragraph using mouse leave function – jquery
To demonstrate this example we are using paragraph with “myPara” id
<p id="myPara">Nothing here in this paragraph.</p>
Wait for the document to get ready for jquery
$(document).ready(function(){});
Using mouse up function in Jquery
$("#myPara").mouseup(function(){});
Using mouse down function in Jquery
$("#myPara").mousedown(function(){});
Using mouse leave function in Jquery
$("#myPara").mouseleave(function(){});
Using hide function in jquery.
$("#myPara").hide();
<html> <head> <title> Here is my title </title> <script src="jquery-3.6.0.min.js"> </script> <link rel="stylesheet" href="bootstrap.min.css"> </head> <body> <p id="myPara">Nothing here in this paragraph.</p> <script> $(document).ready(function(){ $("#myPara").mouseleave(function(){ $("#myPara").hide(); }); }); </script> </body> </html>