avoid opacity of an img placed in a DIV with opacity - HTML CSS CSS Property

HTML CSS examples for CSS Property:opacity

Description

avoid opacity of an img placed in a DIV with opacity

Demo Code

ResultView the demo in separate window

<html>
 <head> 
  <meta name="viewport" content="width=device-width, initial-scale=1"> 
  <style id="compiled-css" type="text/css">
.addFav {<!--   ww  w.ja  v  a 2s. c  om-->
   background:Chartreuse;
   border:2px solid yellow;
   height:201px;
   width:201px;
   color:blue;
   padding:16px;
}
</style> 
 </head> 
 <body> 
  <div class="addFav"> 
   <div> 
    <img src="https://www.java2s.com/style/demo/InternetExplorer.png"> 
   </div> 
  </div>  
 </body>
</html>

Related Tutorials