Position fixed with width 100% - HTML CSS CSS Layout

HTML CSS examples for CSS Layout:Fixed Position

Description

Position fixed with width 100%

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<!--from  w w w.j  a v  a 2s.  c om-->
 {
   margin:0;
   padding:11px;
}

div
 {
   background:red;
   width:calc(100% - 11px);
   height:100px;
   position:fixed;
   bottom:6px;
   left:6px;
}
</style> 
 </head> 
 <body> 
  <div></div>  
 </body>
</html>

Related Tutorials