爱易网
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 浏览次数:20248 次
欢迎光临爱易网网页脚本特效中心,点击运行按钮演示特效:
以下是程序代码
有什么问题请到<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 全部选择 提示:你可先修改部分代码,再按运行]
上一篇:狡猾的按钮特效
下一篇:真正的鼠标右键屏蔽
免责声明:
本文仅代表作者个人观点,与爱易网无关。其原创性以及文中陈述文字和内容未经本站证实,对本文以及其中全部或者部分内容、文字的真实性、完整性、及时性本站不作任何保证或承诺,请读者仅作参考,并请自行核实相关内容。
相关资料
更多>
从雷军的“互联网七字诀”告诉你一个非妖魔化的小米
Android应用审核乱象:诈骗软件冲上排行榜首
搜房网遭遇做空 利益保送成“猎杀”焦点
华为美国推出电商网站 发售Mate 2LTE版
微信收费形式三选一 腾讯或变身运营商
成本效益全兼顾 混合云市场前景显现
特斯拉将获上海免费牌照 充电桩面临双重标准
摩托罗拉移动裁员关闭德州Moto X手机工厂
评论:马云的成功建立在什么基础上很值得怀疑
推荐阅读
更多>
阿里巴巴上市后雅虎将面临更大的业绩压力
中国首台比特币ATM登陆上海 可购买不可兑换现钞
苹果App Store被大量刷榜:iTunes账号成帮凶
地图导航骤起杀机 百度高德重新定义商业模式
迅雷欲3300万美元收购金山快盘 预计9月完成
微软小冰复活再战移动端:改与米聊、易信和触宝合作
流浪汉高考状元终于找到工作:月薪3000做程序员很满意
2013年至今中国互联网行业十大并购案汇总
亚马逊落户上海自贸区:美国货直邮中国
互联网金融一周年:余额宝最接地气,比特币最作死
支付宝被曝严重破绽 隐私平安再受质疑
携程收买酷讯成定局:转型互联网+投资
摩托罗拉中国区将再裁员 助力公司变身
创维冲击500亿梦想:转型硬件和内容供应商
苹果iWatch或使用量产液态金属 将取代玻璃
这一次,微软将带给我们什么惊喜?
互联网情色众多 Facebook与9158态度大不同
HTC曝出特大丑闻:高管诈骗+商业间谍
乐视今日临时停牌 受广电酝酿新规消息影响
传诺基亚5月14日发布会推出Lumia 950