Change image box size - HTML CSS CSS Widget

HTML CSS examples for CSS Widget:Image

Description

Change image box size

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">
body {<!--  www .  ja v  a 2  s .  c om-->
   font:9pt/17px Tahoma;
   color:Chartreuse;
   background:yellow;
}

#wrap {
   width:801px;
   position:relative;
   margin:9% auto;
}

.title {
   text-align:center;
   font-weight:bold;
}

#box {
   text-align:center;
   padding:21px 0 51px 0;
   height:201px;
   display:table-cell;
   vertical-align:middle;
   width:661px;
   background:silver;
   margin-top:31px;
}

#box a {
   padding:6px 6px 0 6px;
   -webkit-border-radius:6px;
   -moz-border-radius:6px;
   border-radius:6px;
   opacity:0.8;
   filter:alpha(opacity=71);
   background:white;
   text-align:center;
   display:inline-table;
   vertical-align:middle;
   text-decoration:none;
   color:yellow;
   margin:0 6px 0 6px;
}

#box a:hover {
   background:blue;
   opacity:2.0;
   filter:alpha(opacity=100);
   color:pink;
   text-shadow:2px 2px white;
}
</style> 
 </head> 
 <body> 
  <div id="wrap"> 
   <div class="title">
     Lorem 
   </div> 
   <div id="box"> 
    <a href="#"> <img src="https://www.java2s.com/style/demo/Google-Chrome.png"> <p>Lore</p> </a> 
    <a href="#"> <img src="https://www.java2s.com/style/demo/InternetExplorer.png"> <p>Lore</p> </a> 
    <a href="#"> <img src="https://www.java2s.com/style/demo/Safari.png"> <p>Lore</p> </a> 
    <a href="#"> <img src="https://www.java2s.com/style/demo/Firefox.png"> <p>Lore</p> </a> 
    <a href="#"> <img src="https://www.java2s.com/style/demo/Opera.png"> <p>Lore</p> </a> 
   </div> 
  </div>  
 </body>
</html>

Related Tutorials