用于布局架构:
#outer{
overflow:hidden;
}
#outer .panel{
float:right;
width:286px;
padding-left:21px;
border-left:1px solid #E5E3D7;
padding-bottom: 27670px !important;
margin-bottom: -27670px !important;
}
#outer .main{
float:left;
width:510px;
padding-bottom: 27670px !important;
margin-bottom: -27670px !important;
}
用于表格的JS代码:
<script>
function div(){
var l=document.getElementById("div1").getElementsByTagName("li");
var num=4;
var i=l.length / num ;
for(var a=0;a<i;a++)
{
var max=l[num*a].scrollHeight;
var kk=num*a;
var dd=num*a;
for(kk;kk<l.length;kk++)
{
if(max<l[kk].scrollHeight)
{
max=l[kk].scrollHeight;
}
if(kk==num*(a+1)-1)
break;
}
for(dd;dd<l.length;dd++)
{
l[dd].style.height=max+"px";
if(dd==num*(a+1)-1)
break;
}
}
}
</script>
PS:在div里面调用div()就把里面的li重复4列的循环!