⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 807back1.htm

📁 最完整的Javascript 特效
💻 HTM
字号:
<html><!-- Mirrored from www.yesky.com/imagesnew/software/jscript/807back1.htm by HTTrack Website Copier/3.x [XR&CO'2007], Tue, 15 Apr 2008 09:00:02 GMT --><head><title>星星从背景中飞出</title><style type="text/css"><!--body {  font-family: "宋体"; font-size: 9pt; margin-top: 0px; margin-left: 4px; margin-right: 0px}A { COLOR: black; FONT-SIZE: 13px; FONT-WEIGHT: 400; TEXT-DECORATION: none } A:hover { COLOR: red; FONT-SIZE: 13px; FONT-WEIGHT: 400; TEXT-DECORATION: underline }a:active     { font: 9pt "宋体"; cursor: hand; color: #FF0033 }--></style><meta http-equiv="Content-Type" content="text/html; charset=gb2312"><style type="text/css">.star {position:absolute;layer-background-color:white;visibility:visible;top:-50px;width:50px;height:50px;font-size:1px;background-color:white;}</style><SCRIPT LANGUAGE="JavaScript"><!-- Beginvar starnum = 175; // Number of starsvar isNS = (document.layers);var _all = (isNS)? '' : 'all.';var _style = (isNS) ? '' : '.style';var xoffset, yoffset, w_x, w_y, tmpx, tmpy, scrlx, scrly;function getstartpos(obj) {obj.deltay = Math.floor(Math.random() * 12);obj.deltax = Math.floor(Math.random() * 12);obj.xdir = (Math.floor(Math.random() * 2) == 1) ? '+' : '-';obj.ydir = (Math.floor(Math.random() * 2) == 1) ? '+' : '-';obj.counter = 1;if (isNS) {obj.clip.width = 1;obj.clip.height = 1;obj.moveTo(xoffset+pageXOffset, yoffset+pageYOffset);} else {obj.width = 1;obj.height = 1; obj.pixelTop = yoffset+document.body.scrollTop;obj.pixelLeft = xoffset+document.body.scrollLeft;   }}function movestar(starN) {tmpx = starN.deltax*starN.counter+starN.counter;tmpy = starN.deltay*starN.counter+starN.counter;if (isNS) {starN.clip.width = starN.counter / 3;starN.clip.height = starN.counter / 3;scrlx = pageXOffset;scrly = pageYOffset;if ((starN.left+tmpx >= w_x+scrlx) || (starN.top+tmpy >= w_y+scrly) || (starN.left-tmpx <= scrlx) || (starN.top-tmpy <= scrly)) {getstartpos(starN);} else {eval('starN.moveBy('+starN.xdir+tmpx+', '+starN.ydir+tmpy+')');   }} else {starN.width = starN.counter/3;starN.height = starN.counter/3;scrlx = document.body.scrollLeft;scrly = document.body.scrollTop;if ((starN.pixelLeft+tmpx >= w_x+scrlx)||(starN.pixelTop+tmpy >= w_y+scrly) || (starN.pixelLeft-tmpx <= scrlx)||(starN.pixelTop-tmpy <= scrly)) {getstartpos(starN);} else {eval('starN.pixelTop'+starN.ydir+'=tmpy');eval('starN.pixelLeft'+starN.xdir+'=tmpx');   }}starN.counter++;}function animate() {for(i=1; i <= starnum; i++) {movestar(eval('star'+i));}setTimeout('animate()', 100);}function findwindowparams() {w_x = (isNS) ? window.innerWidth : document.body.clientWidth;w_y = (isNS) ? window.innerHeight : document.body.clientHeight;xoffset = w_x / 2;yoffset = w_y / 2;for (i = 1; i <= starnum; i++) {getstartpos(eval('star'+i));   }}function resizeNS() {setTimeout('document.location.reload()', 400);}(isNS) ? window.onresize = resizeNS : window.onresize = findwindowparams;window.onload = new Function("findwindowparams(); animate();");//  End --></script></head><body bgcolor=black><br><br><center><font color=red face="隶书" size=6>星星从背景中飞出</font></center><br><SCRIPT LANGUAGE="JavaScript"><!-- Beginfor (i = 1; i <= starnum; i++) {document.writeln('<div id="star'+i+'" class="star"></div>');eval('var star'+i+'=document.'+_all+'star'+i+_style);}// End --></script><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><center><SCRIPT LANGUAGE="JavaScript"><!-- hidefunction goHist(a){   history.go(a);}//--></script><FORM METHOD="post"><INPUT TYPE="button" VALUE="返回" onClick="goHist(-1)" ></form></center><br><center><textarea name=source rows=12 cols=55 class=yk9>脚本说明:第一步:把如下代码加入<!-- Mirrored from www.yesky.com/imagesnew/software/jscript/807back1.htm by HTTrack Website Copier/3.x [XR&CO'2007], Tue, 15 Apr 2008 09:00:02 GMT --><head>区域中:<style type="text/css">.star {position:absolute;layer-background-color:white;visibility:visible;top:-50px;width:50px;height:50px;font-size:1px;background-color:white;}</style><SCRIPT LANGUAGE="JavaScript"><!-- Beginvar starnum = 175; // Number of starsvar isNS = (document.layers);var _all = (isNS)? '' : 'all.';var _style = (isNS) ? '' : '.style';var xoffset, yoffset, w_x, w_y, tmpx, tmpy, scrlx, scrly;function getstartpos(obj) {obj.deltay = Math.floor(Math.random() * 12);obj.deltax = Math.floor(Math.random() * 12);obj.xdir = (Math.floor(Math.random() * 2) == 1) ? '+' : '-';obj.ydir = (Math.floor(Math.random() * 2) == 1) ? '+' : '-';obj.counter = 1;if (isNS) {obj.clip.width = 1;obj.clip.height = 1;obj.moveTo(xoffset+pageXOffset, yoffset+pageYOffset);} else {obj.width = 1;obj.height = 1; obj.pixelTop = yoffset+document.body.scrollTop;obj.pixelLeft = xoffset+document.body.scrollLeft;   }}function movestar(starN) {tmpx = starN.deltax*starN.counter+starN.counter;tmpy = starN.deltay*starN.counter+starN.counter;if (isNS) {starN.clip.width = starN.counter / 3;starN.clip.height = starN.counter / 3;scrlx = pageXOffset;scrly = pageYOffset;if ((starN.left+tmpx >= w_x+scrlx) || (starN.top+tmpy >= w_y+scrly) || (starN.left-tmpx <= scrlx) || (starN.top-tmpy <= scrly)) {getstartpos(starN);} else {eval('starN.moveBy('+starN.xdir+tmpx+', '+starN.ydir+tmpy+')');   }} else {starN.width = starN.counter/3;starN.height = starN.counter/3;scrlx = document.body.scrollLeft;scrly = document.body.scrollTop;if ((starN.pixelLeft+tmpx >= w_x+scrlx)||(starN.pixelTop+tmpy >= w_y+scrly) || (starN.pixelLeft-tmpx <= scrlx)||(starN.pixelTop-tmpy <= scrly)) {getstartpos(starN);} else {eval('starN.pixelTop'+starN.ydir+'=tmpy');eval('starN.pixelLeft'+starN.xdir+'=tmpx');   }}starN.counter++;}function animate() {for(i=1; i <= starnum; i++) {movestar(eval('star'+i));}setTimeout('animate()', 100);}function findwindowparams() {w_x = (isNS) ? window.innerWidth : document.body.clientWidth;w_y = (isNS) ? window.innerHeight : document.body.clientHeight;xoffset = w_x / 2;yoffset = w_y / 2;for (i = 1; i <= starnum; i++) {getstartpos(eval('star'+i));   }}function resizeNS() {setTimeout('document.location.reload()', 400);}(isNS) ? window.onresize = resizeNS : window.onresize = findwindowparams;window.onload = new Function("findwindowparams(); animate();");//  End --></script>第二步:把<body>中加入如下代码:<SCRIPT LANGUAGE="JavaScript"><!-- Beginfor (i = 1; i <= starnum; i++) {document.writeln('<div id="star'+i+'" class="star"></div>');eval('var star'+i+'=document.'+_all+'star'+i+_style);}// End --></script></textarea><br><br><script language="Javascript">document.write("<img src='http://counter.yesky.com/counter.shtml?CID=54197&amp;AID=-1&amp;refer="+escape(document.referrer)+"&amp;cur="+escape(document.URL)+"' border='0' alt='' width='0' height='0'>");</script><noscript><img src="http://counter.yesky.com/counter.shtml?CID=54197&amp;AID=-1&amp;refer=noscriptcounter&amp;cur=noscriptcounter" border='0' width='0' height='0'/></noscript><IFRAME frameBorder=0 scrolling=no src="http://homepage.yesky.com/b_contentsd.html" width=600 height=170></IFRAME></body><!-- Mirrored from www.yesky.com/imagesnew/software/jscript/807back1.htm by HTTrack Website Copier/3.x [XR&CO'2007], Tue, 15 Apr 2008 09:00:02 GMT --></html>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -