有一个CSS文件
内容如下:*div #div-gridview { overflow:auto!important;
left: 0px!important;
padding-right: 0px!important;
padding-bottom: 0px!important;
padding-left: 0px!important;
padding-top: 0px!important;
margin: 0px!important;
border-right: 0px solid!important;
border-top: 0px solid!important;
border-left: 0px solid!important;
border-bottom: 0px solid!important;
position:relative!important;
z-index:0!important;
}
/* Locks table header */
*th {
position:relative!important;
top:expression(this.offsetParent.scrollTop)!important;
}
在IE6也能正常显示
在IE7下 如果前面的字符有换行<br/> 前面的文字发生重叠在线等答案 立马结巾
内容如下:*div #div-gridview { overflow:auto!important;
left: 0px!important;
padding-right: 0px!important;
padding-bottom: 0px!important;
padding-left: 0px!important;
padding-top: 0px!important;
margin: 0px!important;
border-right: 0px solid!important;
border-top: 0px solid!important;
border-left: 0px solid!important;
border-bottom: 0px solid!important;
position:relative!important;
z-index:0!important;
}
/* Locks table header */
*th {
position:relative!important;
top:expression(this.offsetParent.scrollTop)!important;
}
在IE6也能正常显示
在IE7下 如果前面的字符有换行<br/> 前面的文字发生重叠在线等答案 立马结巾
left: 0px;
padding:0;
margin: 0 auto;
border-right: 0px;
border-top: 0px;
border-left: 0px;
border-bottom: 0px;
position:relative;
z-index:0;
}你加了!important只是针对IE7的,并不需要都加,只要在一些IE7特殊的样式前面加上就行了
你以为全中国都跟你一样用IE8啊,现在中国大部分用户都还在用IE6,根本就没想过要升级。