//oBoxs[i].style.left=oBoxs[index].style.left; 与oBoxs[i].style.left=oBoxs[index].offsetLeft+"px";为什么不等同
if(i<cols){
hArr.push(oBoxs[i].offsetHeight);
}else{
var minH=Math.min.apply(null,hArr);
var index=getMinhIndex(hArr,minH);//封装 找最小值的索引
oBoxs[i].style.position="absolute";
oBoxs[i].style.top=minH+"px";
//oBoxs[i].style.left=oBoxs[index].style.left;
oBoxs[i].style.left=oBoxs[index].offsetLeft+"px";
hArr[index]+=oBoxs[i].offsetHeight;
}
}