|
|
|
| Помогите сделать JavaScript
Нужно, чтобы когда наводил на rows в таблице то цвет backgrounda менялся сначала на один а потом на другой(мигание - только два раза ) | |
|
|
|
|
|
|
|
для: Alexx
(08.11.2005 в 17:53)
| |
<table border=1 width=400><tr onmouseover=f(this)><td> ...</td></tr>
<tr onmouseover=f(this)><td> ...</td></tr>
<tr onmouseover=f(this)><td> ...</td></tr>
<tr onmouseover=f(this)><td> ...</td></tr></table>
<script>
T=new Object;I=-1;
function f(t){t.style.backgroundColor='#aa6666';T[++I]=t;setTimeout("T["+I+"].style.backgroundColor='white';",333);}
</script>
|
| |
|
|
|
|
|
|
|
для: 12345
(08.11.2005 в 21:43)
| | работает, а как сделать чтобы когда курсор задерживаешь на строчке то строчка мигала? | |
|
|
|
|
|
|
|
|
для: 12345
(10.11.2005 в 14:39)
| | коментариии пожалуста к сылке ? | |
|
|
|
|
|
|
|
для: Alexx
(10.11.2005 в 15:29)
| | Как говорят на другом сайте, по законченным заданиям обращайтесь в отдел "Работа". (я там не участвую) ; ) | |
|
|
|
|
|
|
|
для: Alexx
(10.11.2005 в 13:23)
| |
<script>
col = new Array()
col[0]="000000"
col[1]="ffffff"
i_col=0
doani=1
var timer
var thislink
function animatelink() {
if (document.all) {
if (doani==1) {
if (i_col<=col.length-1) {
thislink.color=col[i_col]
i_col++
timer=setTimeout("animatelink()",50)
}
else {
i_col=0
timer=setTimeout("animatelink()",50)
}
}
else {
clearTimeout(timer)
}
}
}
function stopanimation() {
clearTimeout(timer)
thislink.color="#dadada"
doani=0
}
function startanimation(mylink) {
clearTimeout(timer)
thislink=eval("document.all."+mylink+".style")
doani=1
animatelink()
}
</script>
<a id=link1 href="#" onmouseover="startanimation('link1')" onmouseout="stopanimation()">Photo</a>
|
| |
|
|
|