告诉它保持静态的 CSS
#fruko {
position: fixed;
}
#links {
position: fixed;
}
Div标签所在的HTML
<td width="225px"><div id="fruko"><p><a href="#top" style="text-decoration: none"><font color="Red" size="8">Fruko, inc.</font></a></p></div></td>
<td><div id="links"><table border="5" cellpadding="5" cellspacing="0" width="100%">
<tr>
<td align="center"><a href="#apps" style="text-decoration: none"><font size="6" color="Red">Apps</font></a></td>
<td align="center"><a href="#programs" style="text-decoration: none"><font size="6" color="Red">Programs</font></a></td>
<td align="center"><a href="#webs" style="text-decoration: none"><font size="6" color="Red">Websites</font></a></td>
<td align="center"><a href="#news" style="text-decoration: none"><font size="6" color="Red">News</font></a></td>
<td align="center"><a href="#social" style="text-decoration: none"><font size="6" color="Red">Social</font></a></td>
<td align="center"><a href="#about" style="text-decoration: none"><font size="6" color="Red">About</font></a></td>
</tr>
</table>
</div></td>
顶部主表旁边的表在 Firefox 中不会拉伸(stretch),但在 IE 中会拉伸(stretch)。
自己测试一下here .
最佳答案
您可以使用 Internet Explorer 条件注释加载专门为 IE 定制的样式。
http://msdn.microsoft.com/en-us/library/ms537512(v=vs.85).aspx
这并不能解决应该普遍使用跨浏览器 CSS 的问题的根源,但它确实有效地满足了诸如此类的需求。
关于html - 静态 header 在 Firefox 中覆盖正文,在 IE 中不是静态的,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/9346064/