'visibility' Example : visibility « CSS Attributes and Javascript Style Properties « HTML CSS Reference






'visibility' Example

    
<html>
<body>
<p>
<img id="myImg" src="http://www.java2s.com/style/logo.png">
</p>
<input type="button" 
       value="Set visibility property to hidden"
       onclick="myImg.style.visibility='hidden'">
       
<input type="button" 
       value="Set visibility property to visible"
       onclick="myImg.style.visibility='visible'">
</body>
</html>

    
      
      








Related examples in the same category

1.'visibility' Syntax and Note
2.'visibility' Possible Values
3.'visibility' is applied to