如果其中一个 DIV 中有一个 100% 宽度 + 非零边距的表格,则 IE 7 和 IE 8 不会在同一行使用 float:left 渲染 2 个后续 div:
<html>
<head>
<title>IE float left bug</title>
<style type="text/css">
.inttable
{
width: 100%;
margin: 9px;
}
.multicolumn
{
margin: 0px;
border: 0px;
padding: 0px;
width:100%;
}
.column
{
margin: 0px;
border: 0px;
padding: 0px;
float:left;
display: inline;
}
</style>
</head>
<body>
<div class="multicolumn">
<div class="column" style="width:50%;">
<table class="inttable">
<tr>
<td>table1</td>
</tr>
</table>
</div>
<div class="column" style="width:50%;">
column 2
</div>
</div>
</body>
</html>
在 FireFox、Opera、Chrome 和 Safari 中没有这样的问题。
有谁知道这个 IE 错误的解决方法?