side by side div with dynamic width


Often we need to build two divs standing side by side, with their width variable (dynamic)



The following code - will help you do it

<div id="container"> 
   <div id="left"> Div 1 - What is my size</div> 
   <div id="right"> Div 2 -I am the <br />Right DIV</div> 
</div>
<style type="text/css"> 
#left {   background: #aaa;   float: left }
#right {   background: cyan;   overflow: hidden } 
#container {   width :400px; } 
</style>

Yours,
Roi

Comments

Popular posts from this blog

A sharepoint list view of the current month

The specified path, file name, or both are too long. The fully qualified file name must be less than 260 characters

Export SharePoint 2010 List to Excel with PowerShell