<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> <html> <head> <script> function overIt(){ var the_obj = event.srcElement; if(the_obj.tagName.toLowerCase() == "td"){ the_obj=the_obj.parentElement; the_obj.oBgc=the_obj.currentStyle.backgroundColor; the_obj.oFc=the_obj.currentStyle.color; the_obj.style.backgroundColor='#71BAF0'; the_obj.style.color=''; } } function outIt(){ var the_obj = event.srcElement; if(the_obj.tagName.toLowerCase() == "td"){ the_obj=the_obj.parentElement; the_obj.style.backgroundColor=the_obj.oBgc; the_obj.style.color=the_obj.oFc; the_obj.style.textDecoration=''; } } </script> </head> <body> <table border=1 width=400 onmouseover="overIt()" onmouseout="outIt()"> <tr bgColor=#111111> <td>aaa</td> <td>aaa</td> <td>aaa</td> <td>aaa</td> </tr> <tr bgColor=#222222> <td>aaa</td> <td>aaa</td> <td>aaa</td> <td>aaa</td> </tr> <tr bgColor=#333333> <td>aaa</td> <td>aaa</td> <td>aaa</td> <td>aaa</td> </tr> <tr bgColor=#444444> <td>aaa</td> <td>aaa</td> <td>aaa</td> <td>aaa</td></tr> <tr bgColor=#555555> <td>aaa</td> <td>aaa</td> <td>aaa</td> <td>aaa</td> </tr> </table> </body> </html>
以上是小编为您精心准备的的内容,在的博客、问答、公众号、人物、课程等栏目也有的相关内容,欢迎继续使用右上角搜索按钮进行搜索color
, aaa
, backgroundcolor
, style
, 整行
, parentElement
, 鼠标划过行变色
, 行变色
currentStyle
鼠标划过变色、鼠标划过变色css ease、鼠标划过图片变化代码、鼠标划过代码、雨滴鼠标划过声音代码,以便于您获取更多的相关知识。
时间: 2024-09-10 18:42:13