<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>无标题文档</title>
</head>
<style type="text/css">
.a1{ background-color:#B3C1F4; color:#0E30AE}
.a2{ background-color:#EDF1FF; color:#0E30AE}
</style>
<script type="text/javascript">
<!--
function onloadEvent(func){
var one=window.onload
if(typeof window.onload!='function'){
window.οnlοad=func
}
else{
window.οnlοad=function(){
one();
func();
}
}
}
function showtable(){
var tablename=document.getElementById("table1")
var tr1=tablename.getElementsByTagName("tr")
for(var i=1 ;i<tr1.length;i++){
tr1[i].οnmοuseοver=function(){
this.style.fontWeight="bold";
this.style.backgroundColor="#fff";
}
tr1[i].οnmοuseοut=function(){
this.style.fontWeight=""
this.style.backgroundColor=""
}
if(i%2==0){
tr1[i].className="a1";
}else{
tr1[i].className="a2";
}
}
}
onloadEvent(showtable);
-->
</script>
<body>
<table width="600" border="0" cellpadding="0" cellspacing="0" style="border:1px solid #4E5547" id="table1">
<tr bgcolor="#0E30AE" style="color:#fff;">
<td width="10%" height="21" background="../images/a_bg1.gif"></td>
<td width="65%" background="../images/a_bg1.gif">标题</td>
<td width="15%" background="../images/a_bg1.gif">发布人</td>
<td width="10%" background="../images/a_bg1.gif">操作</td>
</tr>
<tr>
<td> </td>
<td> </td>
<td> </td>
<td> </td>
</tr>
<tr>
<td>wert</td>
<td> </td>
<td> </td>
<td> </td>
</tr>
<tr>
<td>wert</td>
<td> </td>
<td> </td>
<td> </td>
</tr>
<tr>
<td>weert</td>
<td> </td>
<td> </td>
<td> </td>
</tr>
<tr>
<td>dg</td>
<td> </td>
<td> </td>
<td> </td>
</tr>
</table>
</body>
</html>
发一个隔行换色,鼠标经过变色,ONMOUSEOVER变色
最新推荐文章于 2024-01-16 10:34:03 发布