页脚高度在大分辨率上拉伸

时间:2014-05-05 17:52:54

标签: css twitter-bootstrap

我的网站设计(使用Bootstrap)是当用户滚动到底部时,固定标题触及页脚中的链接。在小屏幕上它工作正常。像这样 -

enter image description here

但是在较大的屏幕分辨率(1024x768向上)上,标题会在到达页脚之前停止。像这样 -

enter image description here

我知道html和body必须有一个已定义的高度,所以添加了这个 -

html, body {
height:100%;
}

但没有奏效。

我也试过给页脚一个高度 -

    #bottom{
border-top: none;
font-family: Calibri, san-serif; 
letter-spacing:2px;
text-transform:uppercase;
color:#000!important;
font-size: 20px;

    }

    .botwid{
min-height: 500px;
padding-top: 35px;
width: 100%;
margin: 0 555px;

但这也不起作用。

Here is my site

由于

1 个答案:

答案 0 :(得分:0)

似乎页脚的margin-bottom必须是(screenHeight - titleHeight)。尝试使用javascript设置此属性(因为每当窗口大小更改时它都会更改)。

使用JQuery,可以使用 .resize()致电。