帮小弟做个 鼠标跟随 吧(情有独钟)这4个字做成跟随吧代码给我就行了
- 提问者网友:别再叽里呱啦
- 2021-05-16 10:18
- 五星知识达人网友:动情书生
- 2021-05-16 10:29
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" " http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns=" http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>无标题文档</title>
</head>
<body>
<marquee id="curscroll" >情有独钟</marquee>
<script language="JavaScript">
var dismissafter=0//设置时间,显示滚动内容
var initialvisible=0
function followcursor(e){
var curscroll=document.getElementById("curscroll");
if (initialvisible==0){
curscroll.style.visibility="visible"
initialvisible=1
}
e=window.event?window.event:e;
curscroll.style.left=document.documentElement.scrollLeft+e.clientX+10+"px";
curscroll.style.top=document.documentElement.scrollTop+e.clientY+10+"px";
}
function dismissmessage(){
curscroll.style.visibility="hidden"
}
document.onmousemove=function(e){
followcursor(e);
}
document.ondblclick=dismissmessage
if (dismissafter!=0)
setTimeout("dismissmessage()",dismissafter*1000)
//-->
</script>
</body>
</html>
- 1楼网友:一袍清酒付
- 2021-05-16 11:30