Jquery links click stopping - Javascript jQuery

Javascript examples for jQuery:Link

Description

Jquery links click stopping

Demo Code

ResultView the demo in separate window

<html>
   <head> 
      <meta name="viewport" content="width=device-width, initial-scale=1"> 
      <script type="text/javascript" src="https://code.jquery.com/jquery-1.5.2.js"></script> 
      <script type="text/javascript">
    $(window).load(function(){//  ww w  . ja va  2s  .  c  om
$("a").click(function(e){
e.preventDefault();
console.log("hi?");
});
    });

      </script> 
   </head> 
   <body> 
      <a href="http://java2s.com/">Let's go!</a>  
   </body>
</html>

Related Tutorials