用 th 原因
th {
background-color: #ffff82;
position: relative;
top: expression(document.getElementById( "divTableContainer ").scrollTop);
z-index: 10;
font-weight:normal;
}
不是吧 这个例子 是你找来的?
th {
background-color: #ffff82;
position: relative;
top: expression(document.getElementById( "divTableContainer ").scrollTop);
z-index: 10;
font-weight:normal;
}
不是吧 这个例子 是你找来的?
解决方案 »
- 我想在前台页面调用后台带参函数内容中有dao2.findByPbrandname("hiddentext1"),怎么把前台文本框的内容作为参数传入,求助!
- 使用jQuery的tablesorter设置表头样式
- 用ajax做删除,数据库的内容删除掉了,但是界面的没有去掉
- JS怎么获取服务器控件对象??????????
- 如何实现前台数据和后台的交互问题
- 屏蔽ie快捷键 alt+f问题
- 如何根据条件改变table单元格的颜色?
- 文字闪动特效
- js获取连接对象的问题
- JavaScript与Jscript有什么区别?
- 如何检测某个table 中的checkbox选中(个数不确定,从数据库读的)
- 如何用js去设置按钮不可用的属性 disabled?
表头多重要啊 默认加粗一下 合情合理
font-weight:normal;
加这个才是把它属性改变了
起作用的是你的expression 脚本
跟文字样式无关
th,td{font:````,color:``````等}
background-color: #ffff82;
position: relative;
top: expression(document.getElementById( "divTableContainer ").scrollTop);
z-index: 10;
font-weight:normal;
} 这样写的话,字体是调过来了,但table不能锁定了?
<html>
<head>
<title> 行列锁定 </title>
<style type="text/css">
table {
border: #a4cdf2 1px solid;
}
th {
border: #a4cdf2 1px solid;
font-family: "courier new";
font-size: 11pt;
background-color: #ffff82;
position: relative;
top: expression(document.getElementById("divTableContainer").scrollTop);
z-index: 10;
font-weight:normal;
}
th.lock {
border: #a4cdf2 1px solid;
font-family: "courier new";
font-size: 11pt;
background-color: #ffff82;
position: relative;
top: expression(document.getElementById("divTableContainer").scrollTop);
left: expression(document.getElementById("divTableContainer").scrollLeft);
z-index: 11;
}
td.locked {
position: relative;
left: expression(document.getElementById("divTableContainer").scrollLeft);
background-color: #ffff82;
}
td {
border: #a4cdf2 1px solid;
font-family: "courier new";
font-size: 11pt;
} </style>
</head> <body>
<div id="divTableContainer" style="width: 298px; overflow: auto;">
<table cellpadding="0" cellspacing="0" id="tabTarget">
<tr>
<th nowrap class="lock"> Column A </th>
<th nowrap> Column B </th>
<th nowrap> Column C </th>
<th nowrap> Column D </th>
<th nowrap> Column E </th>
</tr>
<tr>
<td class="locked"> R1.1 </td>
<td> R1.2 </td>
<td> R1.3 </td>
<td> R1.4 </td>
<td> R1.5 </td>
</tr>
<tr>
<td class="locked"> R2.1 </td>
<td> R2.2 </td>
<td> R2.3 </td>
<td> R2.4 </td>
<td> R2.5 </td>
</tr>
<tr>
<td class="locked"> R3.1 </td>
<td> R3.2 </td>
<td> R3.3 </td>
<td> R3.4 </td>
<td> R3.5 </td>
</tr>
</table>
</div>
</body> </html> 目前的效果是上下滚动正常,左右滚动时Column A单元格被盖掉了,只需解决这个问题即可!请各位帮忙