<html>
<head>
<title>星星跟随鼠标</title></head>
<body>
<center><h1>星星跟随鼠标示例</h1></center>
<script language="JavaScript">
if (!document.layers&&!document.all)
event="test"
function showtip2(current,e,text){
if (document.all&&document.readyState=="complete"){
document.all.tooltip2.innerHTML='<marquee style="border:1px solid black">'+text+'</marquee>'
document.all.tooltip2.style.pixelLeft=event.clientX+document.body.scrollLeft+10
document.all.tooltip2.style.pixelTop=event.clientY+document.body.scrollTop+10
document.all.tooltip2.style.visibility="visible"}
else if (document.layers){
document.tooltip2.document.nstip.document.write('<b>'+text+'</b>')
document.tooltip2.document.nstip.document.close()
document.tooltip2.document.nstip.left=0
currentscroll=setInterval("scrolltip()",100)
document.tooltip2.left=e.pageX+10
document.tooltip2.top=e.pageY+10
document.tooltip2.visibility="show"}}
function hidetip2(){
if (document.all)
document.all.tooltip2.style.visibility="hidden"
else if (document.layers){
clearInterval(currentscroll)
document.tooltip2.visibility="hidden"}}
function scrolltip(){
if (document.tooltip2.document.nstip.left>=-document.tooltip2.document.nstip.document.width)
document.tooltip2.document.nstip.left-=5
else
document.tooltip2.document.nstip.left=150}
</script>
<script language="JavaScript">
function YY_Layerfx(yyleft,yytop,yyfnx,yyfny,yydiv,yybilder,yyloop,yyto,yycnt,yystep) { //v1.2
if ((document.layers)||(document.all)){
with (Math) {yynextx= eval(yyfnx)}
with (Math) {yynexty= eval(yyfny)}
yycnt=(yyloop && yycnt>=yystep*yybilder)?0:yycnt+yystep;
if (document.layers){
eval(yydiv+".top="+(yynexty+yytop))
eval(yydiv+".left="+(yynextx+yyleft)) }
if (document.all){
eval("yydiv=yydiv.replace(/.layers/gi, '.all')");
eval(yydiv+".style.pixelTop="+(yynexty+yytop));
eval(yydiv+".style.pixelLeft="+(yynextx+yyleft)); }
argStr='YY_Layerfx('+yyleft+','+yytop+',"'+yyfnx+'","'+yyfny+'","'+yydiv+'",'+yybilder+','+yyloop+','+yyto+','+yycnt+','+yystep+')';
if (yycnt<=yystep*yybilder){eval(yydiv+".yyto=setTimeout(argStr,yyto)");} }}
function YY_Mousetrace(evnt) {
if (yyns4)
{if (evnt.pageX) {yy_ml=evnt.pageX; yy_mt=evnt.pageY;} }
else{
yy_ml=(event.clientX + document.body.scrollLeft);
yy_mt=(event.clientY + document.body.scrollTop);}
if (yy_tracescript)eval(yy_tracescript)}
</script>
<div id="tooltip2" style="position:absolute;visibility:hidden;clip:rect(0 150 50 0);width:150px;background-color:lightyellow">
<layer name="nstip" width="1000px" bgColor="lightyellow">
</layer>
</div>
<div id="yyd0"
style="position:absolute; left:10px; top:50px; width:3px; height:3px; z-index:1; background-color: #19636c; layer-background-color: #19636c; border: 1px none #000000; clip: rect(0 3 3 0)"></div><div
id="yyd1"
style="position:absolute; left:20px; top:50px; width:3px; height:3px; z-index:1; background-color: #708574; layer-background-color: #708574; border: 1px none #000000; clip: rect(0 3 3 0)"></div><div
id="yyd2"
style="position:absolute; left:30px; top:50px; width:3px; height:3px; z-index:1; background-color: #379bbf; layer-background-color: #379bbf; border: 1px none #000000; clip: rect(0 3 3 0)"></div><div
id="yyd3"
style="position:absolute; left:40px; top:50px; width:3px; height:3px; z-index:1; background-color: #25184c; layer-background-color: #25184c; border: 1px none #000000; clip: rect(0 3 3 0)"></div><div
id="yyd4"
style="position:absolute; left:50px; top:50px; width:3px; height:3px; z-index:1; background-color: #31bd3c; layer-background-color: #31bd3c; border: 1px none #000000; clip: rect(0 3 3 0)"></div><div
id="yyd5"
style="position:absolute; left:60px; top:50px; width:3px; height:3px; z-index:1; background-color: #c11efd; layer-background-color: #c11efd; border: 1px none #000000; clip: rect(0 3 3 0)"></div>
<script>
var yyns4=window.Event?true:false; var yy_mt = 0; var yy_ml = 0;
document.onmousemove = YY_Mousetrace;
yy_tracescript = '';
if (yyns4){ document.captureEvents(Event.mousemove);
YY_Mousetrace('',',document.YY_Mousetrace1')}
YY_Layerfx(0,0,'yy_ml+cos((15*sin(yycnt/39.83007847812662))+0)*150*(sin(10+yycnt/20)+0.2)*cos(yycnt/20)','yy_mt+sin((15*sin(yycnt/34.224861639800686))+0)*150*(sin(10+yycnt/20)+0.2)*cos(yycnt/20)','document.layers[\'yyd0\']',2000,true,80,0,1);
YY_Layerfx(0,0,'yy_ml+cos((15*sin(yycnt/27.66510707209673))+30)*150*(sin(10+yycnt/20)+0.2)*cos(yycnt/20)','yy_mt+sin((15*sin(yycnt/9.240632767417667))+30)*150*(sin(10+yycnt/20)+0.2)*cos(yycnt/20)','document.layers[\'yyd1\']',2000,true,80,0,1);
YY_Layerfx(0,0,'yy_ml+cos((15*sin(yycnt/16.45318944579641))+60)*150*(sin(10+yycnt/20)+0.2)*cos(yycnt/20)','yy_mt+sin((15*sin(yycnt/16.0564452288292))+60)*150*(sin(10+yycnt/20)+0.2)*cos(yycnt/20)','document.layers[\'yyd2\']',2000,true,80,0,1);
YY_Layerfx(0,0,'yy_ml+cos((15*sin(yycnt/6.95348954836835))+90)*150*(sin(10+yycnt/20)+0.2)*cos(yycnt/20)','yy_mt+sin((15*sin(yycnt/44.13697049887155))+90)*150*(sin(10+yycnt/20)+0.2)*cos(yycnt/20)','document.layers[\'yyd3\']',2000,true,80,0,1);
YY_Layerfx(0,0,'yy_ml+cos((15*sin(yycnt/33.90077294583733))+120)*150*(sin(10+yycnt/20)+0.2)*cos(yycnt/20)','yy_mt+sin((15*sin(yycnt/2.2378828869411587))+120)*150*(sin(10+yycnt/20)+0.2)*cos(yycnt/20)','document.layers[\'yyd4\']',2000,true,80,0,1);
YY_Layerfx(0,0,'yy_ml+cos((15*sin(yycnt/37.858312521039835))+150)*150*(sin(10+yycnt/20)+0.2)*cos(yycnt/20)','yy_mt+sin((15*sin(yycnt/18.083839795990098))+150)*150*(sin(10+yycnt/20)+0.2)*cos(yycnt/20)','document.layers[\'yyd5\']',2000,true,80,0,1);
</script>
</body>
</html>
没有合适的资源?快使用搜索试试~ 我知道了~
精通javascript光盘实例.rar
共491个文件
htm:358个
gif:78个
jpg:9个
需积分: 9 23 下载量 189 浏览量
2007-11-11
21:18:46
上传
评论
收藏 1.4MB RAR 举报
温馨提示
精通javascript原书中的实例程序,1.40M。版权归原作者所有。<br>希望能方便大家学习!!
资源推荐
资源详情
资源评论
收起资源包目录
精通javascript光盘实例.rar (491个子文件)
lyb.asp 71KB
index.asp 58KB
ajax_server.asp 1KB
css.css 975B
css.css 636B
staff.css 342B
green.css 17B
blue.css 16B
red.css 15B
Thumbs.db 174KB
Thumbs.db 50KB
Thumbs.db 33KB
Thumbs.db 24KB
Thumbs.db 20KB
Thumbs.db 19KB
Thumbs.db 17KB
Thumbs.db 9KB
Thumbs.db 5KB
光盘使用说明.DOC 141KB
image1.gif 103KB
image1.gif 103KB
image4.gif 102KB
image4.gif 102KB
1145.GIF 46KB
image1.gif 43KB
image2.gif 26KB
image2.gif 26KB
image1.gif 18KB
image2.gif 13KB
safecolors.GIF 13KB
1145.GIF 13KB
ufo.gif 10KB
image3.gif 9KB
image3.gif 9KB
nonsafecolors.GIF 9KB
image5.GIF 9KB
1146.GIF 9KB
addin.gif 8KB
star.gif 4KB
welcome.gif 2KB
ad-01.gif 2KB
bookbg.gif 2KB
button.gif 1KB
T_right.gif 1KB
T_left.gif 1KB
T_bottomright.gif 1KB
post.gif 1001B
close.gif 984B
back.gif 949B
T_bottomleft.gif 886B
106.gif 849B
115.gif 816B
116.gif 759B
117.gif 707B
111.gif 695B
102.gif 685B
101.gif 670B
108.gif 668B
110.gif 643B
114.gif 637B
109.gif 624B
113.gif 618B
107.gif 592B
103.gif 547B
Ubb_swf.gif 508B
104.gif 502B
come.gif 461B
email.gif 452B
112.gif 452B
reply.gif 444B
homepage.gif 441B
105.gif 425B
Ubb_url.gif 375B
Ubb_email.gif 365B
Ubb_image.gif 296B
Ubb_underline.gif 261B
Ubb_bold.gif 259B
Ubb_center.gif 256B
Ubb_italicize.gif 250B
ip.gif 212B
plus.gif 205B
blue.gif 204B
white.gif 204B
black.gif 204B
red.gif 204B
green.gif 204B
blue.gif 204B
white.gif 204B
black.gif 204B
red.gif 204B
green.gif 204B
open.gif 178B
oicq.gif 162B
del.gif 117B
Tt_bg.gif 94B
T_bottombg.gif 84B
spacer.gif 52B
10.8.htm 5KB
16.19.htm 5KB
ajax.htm 4KB
共 491 条
- 1
- 2
- 3
- 4
- 5
资源评论
beilikou
- 粉丝: 20
- 资源: 52
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
最新资源
- 202304910142原道明(1).pbix
- 文本.txt
- 基于Lua的聊天过滤修改版设计源码
- A1_SSE_123090177.py
- Uibot6.0 (RPA财务机器人师资培训第5天 ) 报销汇总机器人案例实战
- 基于Vue的西安美食攻略应用程序设计源码
- tensorflow-2.6.2-cp38-cp38-win-amd64.whl
- 2023-04-06-项目笔记 - 第八十六阶段 - 4.4.2.84全局变量的作用域-84 -2024.03.28
- 基于C语言解决九宫重排问题(源码+剖析)
- 考研分数计算神器(通过考研分数计算规则制作出来的计算工具,结果精准,操作简单,并且还可以与第二个人进行比较)
资源上传下载、课程学习等过程中有任何疑问或建议,欢迎提出宝贵意见哦~我们会及时处理!
点击此处反馈
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功