My wrapper div css;
.post-wrapper{
width:200px;
min-height:50px;
}
ul list css for .post-wrapper;
.post-wrapper ul{
margin:0;
padding:0;
width:200px;
}
.post-wrapper ul li{
margin-bottom:2px;
padding:0;
list-style:none;
text-align:center;
width:200px;
float:left;
}
HTML
<div class="post-wrapper">
<ul>
<li>Item-1</li>
<li>Item-2</li>
<li>Item-3</li>
<li>Item-4</li>
<li>Item-5</li>
<li>Item-6</li>
<li>Item-7</li>
</ul>
</div>
There is no problem for 5 list item (li) but after 5 post-wrapper don’t stretch. How can solve this problem?
Your problem may be the
float:lefton the li elementTry:
1. add
position:relativeto the wrapper container2. add a clearing div to the bottom of the wrapper