我在使用IE7显示表格时出现问题(不用担心它用于表格数据),其中表格行具有在x轴上重复的背景图像,表格部分(在这种情况下是TH)具有单独的背景图像,根本没有重复。IE7父母与子女背景图像的显示问题
下面是一个例子:
http://cdn.bkit.ca/misc/juniors-table-problem.png
这里的CSS:
<style>
table,
td,
th,
tr {
border: none;
}
table tr {
border-bottom: 1px solid #BEBEBE;
}
table td {
padding: 7px;
border-left: 1px solid #BEBEBE;
border-right: 1px solid #BEBEBE;
}
table th {
padding: 7px;
text-align: left;
}
table .header {
background-image: url(/images/layout/nav_background.png);
background-position: top;
background-repeat: repeat-x;
height: 37px;
border: none;
margin: 2px;
}
table .header th {
color: white;
font-weight: normal;
text-align: center;
}
table .header th.first {
background-color: transparent;
background-image: url(/images/layout/nav_left.png);
background-repeat: no-repeat;
background-position: top left;
}
table .header th.last {
background-image: url(/images/layout/nav_right.png);
background-repeat: no-repeat;
background-position: top right;
background-color: transparent;
}
</style>
而这里的HTML:
<table>
<tr class="header">
<th class="first">a</th>
<th>b</th>
<th class="last">a</th>
</tr>
</table>
请不要责备我的CSS,一些它是“喷洒和祈祷”CSS希望修复它。
所以我不能为我的生活找出为什么我有这个问题。 IE8没有这个问题。
任何想法?