熙海啵啵

标题: 给表格单元格加上七色彩条_层和布局特效 [打印本页]

作者: admin    时间: 2021-5-19 17:51
标题: 给表格单元格加上七色彩条_层和布局特效
复制
<html>
<head>
<meta http-equiv="Content-Type" mrc="text/html; charset=gb2312">
<title>单元格实现的七色彩条</title>
</head>
<body>
<script>
l=Array(6,7,8,9,'a','b','b','c','d','e','f')
t="<table height=5 width=100% cellspacing=0 cellpadding=0><tr>"
for(x=0;x<40;x++){t+="<td id=a_mo"+x+"></td>"}
document.write(t+"</tr></table>")
function f1(y){for(i=0;i<40;i++){c=(i+y)%20;if(c>10)c=20-c
document.all["a_mo"+(i)].bgColor="'#00"+l[c]+l[c]+"00'"}y++
setTimeout('f1('+y+')',1)}f1(1)
</script>
</body>
</html>







欢迎光临 熙海啵啵 (http://cece56.cn/) Powered by Discuz! X3.4