效果说明:
实现鼠标移入和移出对象时的,对象背景渐隐渐现的动态效果。
<SCRIPT language=JavaScript>
<!--
function over(obj, col,idNum) {
changeColor(obj, col);
}
function out(obj,idNum) {
changeColor(obj, "#3B77AB");
}
function changeColor(obj, col) {
obj.filters.blendTrans.apply();
obj.style.backgroundColor= col;
obj.filters.blendTrans.play();
}
//-->
</SCRIPT>
<style>
.login {
width:100px;
height:19px;
background-color:#3B77AB;
filter: blendTrans(duration=0.5);
}
</style>
<div class="login" onMouseOver="over(this, '#EFF8E2',2)" onMouseOut="out(this,2)" >
AAAAAAAAA
AAAAAAAAA
AAAAAAAAA
</div>
效果(鼠标移动到对象上察看):
AAAAAAAAA AAAAAAAAA AAAAAAAAA
posted on 2006-06-30 10:28
kelven 阅读(206)
评论(0) 编辑 收藏 所属分类:
JavaScript