Full width CSS with 2 column, fixed menu width and dynamic content width - HTML CSS CSS Widget

HTML CSS examples for CSS Widget:Menu

Description

Full width CSS with 2 column, fixed menu width and dynamic content width

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">
.main {<!-- w  w  w  .j a va  2s .c o  m-->
   float:left;
   background-color:Chartreuse;
   width:calc(100% - 241px);
   color:yellow;
   background-color:blue;
   box-sizing:border-box;
}

.sidebar {
   float:right;
   background-color:pink;
   width:241px;
}
</style> 
 </head> 
 <body> 
  <div style="width:100%;"> 
   <div class="main" style="">
     Lorem ipsum do 
    <br>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Morbi ullamcorper molestie lacus sed fermentum. Aliquam erat volutpat. Vestibulum tortor neque, ornare vita 
   </div> 
   <div class="sidebar">
     Lorem ipsum 
    <br>Lorem ipsum dolor sit amet, cons 
   </div> 
  </div>  
 </body>
</html>

Related Tutorials