<HTML>
<HEAD>
<SCRIPT LANGUAGE="JavaScript">
<!--
color_num = ["0","1","2","3","4","5","6","7","8","9","a","b","c","d","e","f"];
function mouse_over() {
for (i = 0; i < 13; i++) {
setTimeout('document.frm.button.style.background = '+
"#'+color_num[12-i]+'ff'+color_num[12-i]+'00";', i * 10);
}
}
function mouse_out() {
document.frm.button.value = " 押してみろ! ";
for (i = 0; i < 13; i++) {
setTimeout('document.frm.button.style.background ='+
"#'+color_num[i]+'ff'+color_num[i]+'ff";', i * 10);
}
}
function mouse_down() {
document.frm.button.value = " イテッ!! (>_<) ";
document.frm.button.style.background = "red";
}
//-->
</script>
</HEAD>
<BODY>
<form name=frm>
<input type=button name=button value=" 押してみろ! "
onMouseOver='mouse_over()' onMouseDown='mouse_down()'
onMouseOut='mouse_out()'>
</form>
</BODY>
</HTML>
|