我有一個頁腳定義爲字體變化和自動調整加填充
div#footer {
width:100%;
bottom:0;
background:url(../images/bg_footer0.png) repeat-x;
}
其HTML體設計爲
html,body {
margin:0;
padding:0;
height:100%;
font-family:arial, Helvetica, sans-serif;
color:#666;
background:url(../images/bg_body.png) repeat-x;
font-size:12px;
}
但是當我改變arial
到serif
在字體,頁腳從底部填充,我想這在所有字體變化中都很常見。但是爲什麼以及怎樣才能始終將頁腳添加到底部,無論發生什麼變化?
你能元素絕對位置文本底部:0;或者你可以調整行高; –
'bottom:0'''如果'position:static'沒有效果' – Oriol
它可能是'line-height',嘗試將其設置爲固定值並查看會發生什麼。字體有不同的x高度。 – Maroshii