JS特效-飞舞的彩蝶

  • 一款JS特效-飞舞的彩蝶,哇,是不是好有感觉!还会跟随鼠标移动,鼠标移在哪里,就跟向哪里,纯粹JS实现的效果,没有用到任何的修饰图片,推荐给喜欢网页特效的朋友们。
<html>
<head>
<title>石家庄油漆</title>
</head>
<body><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>
<script language="JavaScript">
function PopWin()
{
var PopWin = window.open("new.htm","PopWin","toolbar=no,directries=no,scrollBars=yes,height=350,width=400");
}
</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>
<p align="center" style="line-height: 20px"><font color="#666666"><span
style="font-size: 9pt"><font size="5" color="#FF6699">哇,是不是好有感觉!</font><br>
  </span></font></p>
<hr size="1" noshade width="100%" color="red">
<p align="center" style="line-height: 20px">
<font face="Arial, Helvetica, sans-serif" color="#666666"></font> 
</body>
</html>

JS特效-飞舞的彩蝶

时间: 2024-10-13 11:02:07

JS特效-飞舞的彩蝶的相关文章

js特效之酷炫的彩虹圈

此代码非本人所写 望使用者不要拿来做商业用途 致谢! <!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><style&

常用js特效

事件源对象  event.srcElement.tagName event.srcElement.type 捕获释放  event.srcElement.setCapture();  event.srcElement.releaseCapture(); 事件按键  event.keyCode event.shiftKey event.altKey event.ctrlKey 事件返回值  event.returnValue 鼠标位置 event.x event.y 窗体活动元素  documen

很不错的js特效

这里有好多的js特效:http://www.jsfoot.com/jquery/images/qh/ jquery图片特效 jquery幻灯片 .... 有什么js需要可以到这里来下载:http://www.jsfoot.com/jquery/images/qh/ 很不错的js特效,布布扣,bubuko.com

改行了,全部源码免费发放,加好友,js特效,html5,php

改行了,全部源码免费发放,加好友,js特效,html5,php改行了,全部源码免费发放,加好友,js特效,html5,php,有什么问题可以问我,知无不言言无不尽,但是有什么需要也可以加我微信,小店自己的东西,便宜实惠!改行了,全部源码免费发放,加好友,js特效,html5,php改行了,全部源码免费发放,加好友,js特效,html5,php,有什么问题可以问我,知无不言言无不尽,但是有什么需要也可以加我微信,小店自己的东西,便宜实惠! 江南,江南,皮革厂,皮革厂,倒闭了,倒闭了,江南皮革城倒闭

又到圣诞节,让你的网页下起雪(js特效)

又到圣诞节,让你的网页下起雪(js特效) 在4年多前,我写过一个特效,就是让你的网页下起雨,它的效果就是在你打开的网站,雨点下满你的屏幕,恩,大概效果如下图: 当然这个效果还有一些附带项,比如风速.风向.雨速.雨量,这些后来发现又变成一个不单纯的东西了,所以又隐藏了,那个时候还没有现在这么流行h5和css3,所以效果会硬一点,只作一个普通的分享. 然后四年前的今天,我又写了一个让网页下起雪来的效果,它会让你的网页飘起一个个的雪花,正适合今天这个圣诞的节日,所以就拿出来献下丑,它的效果图如下: 最

带左右箭头切换的自动滚动图片JS特效

<!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-

JQuery实现感应鼠标弹出气泡框悬停提示的js特效

<!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-

显示和隐藏文字的js特效

<!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><title>显示和隐藏文字的js特效</title&g

免费分享个JS特效工具

原文:免费分享个JS特效工具 源代码下载地址:http://www.zuidaima.com/share/1586986918480896.htm 里边基本用到的特效都差不多有了. 特效页面右击,可以查看代码 版权声明:本文为博主原创文章,未经博主允许不得转载.