html - height: auto doesn't work for parent div - no overflow: auto -


my div projects needs have automatic height because project classes later added dynamically. problem height: auto attribute doesn't work.

html:

<div id="content">     <div id="projects">         <div id="proj1" class="project col-md-4"></div>         <div id="proj2" class="project col-md-4"></div>         <div id="proj3" class="project col-md-4"></div>     </div>     <div id="lanes">         <div id="lane1" class="lane">          </div>     </div> </div> 

css:

#projects {     background-color: pink;     height: auto;     padding: 10px; }  .project {     background-color: yellow;     height: 100px;     border-style: solid;     border-width: 1px; }  .lane {     height: 155px;     background-color: green;     border-style: solid;     border-width: 1px; } 

i can not use overflow: auto or overflow: normal because have draggable divs within projects div, can't dragged out.


Comments

Popular posts from this blog

matlab - "Contour not rendered for non-finite ZData" -

delphi - Indy UDP Read Contents of Adata -

javascript - Any ideas when Firefox is likely to implement lengthAdjust and textLength? -