首页 > IT职业 > IT职场 > 设置 div自适应高度
jQuery('#right').css('min-height',(jQuery('body').height()-175)+"px");
175为top和bottom2部分高的和。也可通过jquery动态获取jQuery('#top').height()+jQuery('#bottom').height()
设置min-height最小高度,这样中间部分高度可以自动扩大
来自 “ ITPUB博客 ” ,链接:https://blog.itpub.net/393/viewspace-2814974/ ,如需转载,请注明出处,否则将追究法律责任。