hidden object clickable - Javascript jQuery

Javascript examples for jQuery:Mouse Event

Description

hidden object clickable

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> 
  <style id="compiled-css" type="text/css">

div {//  www  . ja  va 2s  . c o m
   width: 100%;
   height: 100%;
   visibility: hidden;
}


      </style> 
  <script type="text/javascript">
    $(window).load(function(){
$('div').click(function() {
    console.log('Hello')
});
$('div').click();
    });

      </script> 
 </head> 
 <body> 
  <div>
    abc 
  </div>  
 </body>
</html>

Related Tutorials