Show div using javascript via setting the css style display - Javascript CSS Style Property

Javascript examples for CSS Style Property:display

Description

Show div using javascript via setting the css style display

Demo Code

ResultView the demo in separate window

<html>
   <head> 
      <meta name="viewport" content="width=device-width, initial-scale=1"> 
      <script type="text/javascript">
    window.onload=function(){/* w  w w.j  a  v a2  s.c om*/
var divv = document.getElementById("captcha");
divv.style.display = '';
    }

      </script> 
   </head> 
   <body> 
      <div id="captcha" style="display: none;">
          Test 
      </div>  
   </body>
</html>

Related Tutorials