爱易网
IT新闻
IT新闻
爱易资讯
网站搭建
云虚拟主机教程
云服务器教程
Apache教程
IIS教程
Nginx教程
网站策划
站长文章
推广教程
淘宝客教程
网页设计
HTML教程
XHTML教程
CSS教程
HTML5教程
CSS3教程
JavaSript基础
JQuery教程
Node.js教程
前端技术
Ajax教程
Js特效
Xml教程
平面设计
页面UI设计
photoshop教程
程序开发
AI人工智能
Asp教程
Php教程
Asp.Net教程
Net Core教程
C#教程
Java教程
Jsp教程
开发技术
微信小程序教程
Uniapp开发教程
微信公众号开发
Andriod教程
IOS教程
DOS教程
Python教程
Docker教程
Windows Container教程
数据库
MSSQL教程
MySQL教程
Redis教程
Access教程
Oracle教程
数据库教程
操作系统
Linux教程
Windows教程
MAC教程
Cisco教程
交换机教程
防火墙教程
搜索
爱易网页
JS特效
用程序来记录鼠标在页面中的滑动轨迹
用程序来记录鼠标在页面中的滑动轨迹
日期:2014-05-18 浏览次数:20317 次
欢迎光临爱易网网页脚本特效中心,点击运行按钮演示特效:
以下是程序代码
有什么问题请到<a href='/bbs/index.asp?boardid=2'>论坛</a>中发表 <!-- http://www.aiyiweb.com/ --> <!-- http://bbs.aiyiweb.com --> <!--完成效果须两步: 第一步:把下列代码放到<body>区域中--> <script language="JavaScript"> <!-- var mousex=new Array(); var mousey=new Array(); var i; var j=0; var k; var recordcount=0; var repeat; var repeat2; var repeat3; var speed=50; function startthis() { recordcount=1; i=0; mousex=new Array(); mousey=new Array(); recordthis(); } function recordthis() { if (maxnum.value=='' || isNaN(maxnum.value) == true || maxnum.value<0) { if (recordcount==1) { mousex[i]=mousefollow.offsetLeft; mousey[i]=mousefollow.offsetTop; i++; k=i; textfield.value='无时间限制'; } } else { if (recordcount==1) { if (i<maxnum.value) { mousex[i]=mousefollow.offsetLeft; mousey[i]=mousefollow.offsetTop; i++; k=i; textfield.value='剩余'+(maxnum.value-i)+'/50秒'; } else { recordcount=0; textfield.value='时间到';} } } repeat=setTimeout("recordthis()",20); } function stopthis() { clearTimeout("repeat"); recordcount=0; } function playthis() { clearTimeout("repeat"); clearTimeout("repeat3"); recordcount=0; if (j<i-1) { arrow.style.pixelLeft=mousex[j]; arrow.style.pixelTop=mousey[j]; arrow.style.visibility='visible'; j++; repeat2=setTimeout("playthis()",speed); } else {clearTimeout("repeat2"); arrow.style.visibility='hidden'; j=0; } } function rewindthis() { clearTimeout("repeat"); clearTimeout("repeat2"); recordcount=0; if (k>0) { arrow.style.pixelLeft=mousex[k-1]; arrow.style.pixelTop=mousey[k-1]; arrow.style.visibility='visible'; k--; repeat3=setTimeout("rewindthis()",speed); } else {clearTimeout("repeat3"); arrow.style.visibility='hidden'; k=i; } } function follow() { mousefollow.style.pixelLeft=document.body.scrollLeft+event.clientX; mousefollow.style.pixelTop=document.body.scrollTop+event.clientY; } // --> </script> <div id="arrow" style="position:absolute; width:12px; height:21px; z-index:1;visibility:hidden"><img src="http://www.aiyiweb.com/images/link.gif" onload="return imgzoom(this,600);" onclick="javascript:window.open(this.src);" style="cursor:pointer;"/></div> <div id="mousefollow" style="position:absolute; width:12px; height:21px; z-index:1;visibility:hidden">.</div> <input type="text" name="maxnum" size="4" maxlength="4"><input type=button onclick=startthis() value=录制><input type=button onclick=stopthis() value=停止><input type=button onclick="speed=50;playthis()" value=播放><input type=button onclick="speed=2;playthis()" value=快放><input type=button onclick="speed=150;playthis()" value=慢放><input type=button onclick="speed=50;rewindthis()" value=倒放><input type="button" name="textfield" style="width:100px" value="无时间限制"> <!--第二步:把如下代码加入<body>区域中--> <BODY onmousemove=follow()> <a href="http://www.aiyiweb.com/js/">欢迎访问爱易网JS特效</a>
[Ctrl+A 全部选择 提示:你可先修改部分代码,再按运行]
上一篇:狡猾的按钮特效
下一篇:真正的鼠标右键屏蔽
免责声明:
本文仅代表作者个人观点,与爱易网无关。其原创性以及文中陈述文字和内容未经本站证实,对本文以及其中全部或者部分内容、文字的真实性、完整性、及时性本站不作任何保证或承诺,请读者仅作参考,并请自行核实相关内容。
相关资料
更多>
广电总局回应美剧下架:不是所有信息可公开
网络文学竞争白热化 百度多酷文学网上线
同为70前后人,马云为什么总是像外星人那么瘦
从旗下三大业务BG发展看华为的过去现在和未来
只有切到刚需痛点,漫画APP才能走下去
迅雷向美SEC提交IPO招股书:拟最多筹资1亿美元
MIUI,有了它小米就无惧对手
完美入股盛大:一桩各怀心事的交易
中移动财报外的"五座大山":运营商沦为走秀陪衬
推荐阅读
更多>
Facebook财报前瞻:投资者仍信心不足
分析称iPhone 6明年初发布 屏幕变为4.8吋
玩游戏式的趣味戒烟App:Kwit
携程收买酷讯成定局:转型互联网+投资
微软为避免代理权争夺 与大股东达成和解协议
打车软件火了 恶性循环来了
欧盟控诉苹果在爱尔兰非法进行税收交易
FDD牌照12月将发放 联通电信双4G反击中移动
诺基亚因充电器问题暂停销售Lumia 2520平板电脑
传苹果与雅虎协作信息提供 进一步摆脱谷歌
如家撤离同程内情:祸起反水OTA“联盟”?
屌丝程序猿发家机会来了 用大数据来做生意!
英特尔VS苹果:移动芯片大战
Skype周年:与微软联姻到底有没有未来?
三星已经将Galaxy S5视为失败之作?
AMD Q1净亏1.46亿美元 转战SOC拥抱ARM求变
银河证券王锦炎:金融业如何使用大数据
科技巨匠体验谷歌眼镜:戴上了就不想摘上去
用友软件股价逆势下跌 再融资方案现曙光
NEC拟出售移动效劳子公司NEC Mobile