您的位置:首页 > 其它

随鼠标移动的图片动态效果

2010-01-14 10:51 127 查看
<html>
<head>
<style type="text/css">
.mystyle1{
position:absolute;
left:20;
top:200;
}
</style>
<script type="text/javascript">
function move(x,y){
myPicture.style.left = x;
myPicture.style.top = y;
}
</script>
</head>
<body onmousemove="move(event.x, event.y)">
正文内容
<div class="mystyle1" id="myPicture"><img src="lover.jpg"></div>
<br>
</body>
</html>
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: