CSS Positioning - Best Way To Position - HTML CSS CSS Layout

HTML CSS examples for CSS Layout:Position

Description

CSS Positioning - Best Way To Position

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">
#wrapper {<!--  w w  w .j  a v  a 2s. c o  m-->
   width:451px;
}

#div1,
#div2,
#div3 {
   float:left;
   margin:2em;
   padding:2em;
   border:6px solid Chartreuse;
   border-radius:9px;
}

#div1,
#div2 {
   width:151px;
   height:76px;
}

#div2 {
   clear:left;
}

#div3 {
   float:right;
   width:151px;
   height:226px;
}
</style> 
 </head> 
 <body> 
  <div id="wrapper"> 
   <div id="div3">
     Lorem i 
   </div> 
   <div id="div1">
     Lorem i 
   </div> 
   <div id="div2">
     Lorem i 
   </div> 
  </div>  
 </body>
</html>

Related Tutorials