CSS variable 2 Column Layout - HTML CSS CSS Layout

HTML CSS examples for CSS Layout:2 Column

Description

CSS variable 2 Column Layout

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">

img#textBooks{<!--   w w w  .j  a  v a2s  .  co  m-->
   width:100px
}
img#logo{
}
div.link{
   background-color:#2266cc;
   text-align:center;
}
div#container{
   position:absolute;
   left:10%;
   width:80%;
   border:2px solid black;
   background-color:purple;
   float:left;
}
div#welcome{
   text-align:center;
   font-size:16pt;
   float:left;
   width:100%;
   border:1px solid black;
   background-color:blue;
   opacity:0.5;
}
div#body{
   padding:0px;
   margin:0px;
   border:1px solid black;
   background-color:yellow;
   float:left;
   width:100%;
}
div#info{
   width:50%;
   margin:0px;
   text-align:center;
   background-color:red;
   float:left;
   display:table-cell;
   opacity:0.5;
}
div#textBooks{
   width:50%;
   margin:0px;
   float:left;
   display:table-cell;
   background-color:green;
   opacity:0.5;
}
div#textBooks > div, div#info > div{
   border:1px solid black;
}
a,a:visited{
   text-decoration:none;
   color:black;
}
a:hover{
   color:orange;
}


      </style> 
 </head> 
 <body> 
  <link rel="stylesheet" type="text/css" href="index.css"> 
  <title>Assignment 2 - HTML</title> 
  <meta charset="UTF-8"> 
  <br> 
  <br> 
  <div id="container"> 
   <div id="welcome">
     Welcome
   </div> 
   <div id="body"> 
    <div id="info"> 
     <div>
       hi 
     </div> 
    </div> 
    <div id="textBooks"> 
     <div>
       green 
     </div> 
    </div> 
   </div> 
  </div>  
 </body>
</html>

Related Tutorials