首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 文档频道 > 模板大全 > 其他模板 >

网页特效代码大全(6)

2008-06-29 
function HIDE(divName){
if (document.all)
eval(’document.all.’+divName+’.style.visibility = "hidden";’);
else if (document.layers)
eval(’document.layers["’+divName+’"].visibility = "hide";’);
}
anim_0_x=new Array(20,20,10,0,0,0,0,0,0,0,0,0);
anim_0_y=new Array(-20,-40,-60,-80,-60,-40,-20,0,20,40,60,80);
anim_1_x=new Array(20,20,17,36,60,78,90,92,93,98,108,120,133,152,181);
anim_1_y=new Array(-20,-20,-33,-38,-38,-27,-2,25,51,84,113,141,162,212,253);
anim_2_x=new Array(20,20,2,3,4,5,6,7,8,9,10,12,13,15,18);
anim_2_y=new Array(-20,-20,-33,-38,-38,-27,-2,25,51,84,113,141,162,212,253);
anim_3_x=new Array(-20,-20,-2,-1,7,10,18,35,60,102,94,94,93,97,108,111,117,127);
anim_3_y=new Array(-20,-25,-64,-89,-104,-150,-173,-197,-213,-199,-151,-101,-66,-17,27,87,140,189);
anim_4_x=new Array(-20,-20,-10,-39,-30,-69,-64,-138,-154,-200,-181,-209,-191,-207,-203,-213,-202,-221,-211);
anim_4_y=new Array(-20,-20,-28,-51,-79,-100,-135,-154,-193,-183,-149,-134,-89,-60,8,51,107,157,201);
anim_5_x=new Array(-20,-29,-51,-72,-105,-133,-164,-189,-209,-229,-247,-270,-279,-282,-283,-283,-285,-286,-288);
anim_5_y=new Array(-20,-55,-86,-116,-154,-183,-205,-217,-217,-198,-169,-120,-44,-8,40,87,144,190,248);
anim_6_x=new Array(-20,-20,-7,14,44,79,143,186,217,226,234,244,250,259,265,274);
anim_6_y=new Array(-20,-21,-72,-113,-139,-166,-188,-181,-126,-68,-3,54,134,187,215,257);
anim_7_x=new Array(20,20,-3,-9,-13,-27,-33,-44,-54,-66,-77,-95,-107,-136,-150,-160,-164,-168,-171,-172,-172,-176,-175);
anim_7_y=new Array(-20,-26,-43,-63,-89,-116,-145,-169,-201,-222,-240,-253,-254,-245,-220,-195,-160,-124,-81,-53,-26,19,68);
anim_8_x=new Array(-20,20,-35,39,0,45,-1,24,-15,14,-20,35,-18,38,-11,16,49,64,81,93,100,103,109);
anim_8_y=new Array(-20,-20,-32,-42,-62,-76,-89,-107,-132,-147,-173,-180,-192,-209,-236,-193,-119,-73,-24,51,95,130,188);
anim_9_x=new Array(-20,-51,-89,-110,-165,-191,-228,-240,-259,-271,-277,-281,-287);
anim_9_y=new Array(-20,-20,-35,-37,-34,-16,10,47,105,150,189,227,273);
//  End -->
</script>
<DIV id=sparks>
<DIV id=sDiv0 style="POSITION: absolute; VISIBILITY: hidden"><FONT color=red 
face="arial black">a</FONT></DIV>
<DIV id=sDiv1 style="POSITION: absolute; VISIBILITY: hidden"><FONT color=yellow 
face="arial black">b</FONT></DIV>
<DIV id=sDiv2 style="POSITION: absolute; VISIBILITY: hidden"><FONT color=blue 
face="arial black">c</FONT></DIV>
<DIV id=sDiv3 style="POSITION: absolute; VISIBILITY: hidden"><FONT color=red 
face="arial black">d</FONT></DIV>
<DIV id=sDiv4 style="POSITION: absolute; VISIBILITY: hidden"><FONT color=orange 
face="arial black">e</FONT></DIV>
<DIV id=sDiv5 style="POSITION: absolute; VISIBILITY: hidden"><FONT color=white 
face="arial black">f</FONT></DIV>
<DIV id=sDiv6 style="POSITION: absolute; VISIBILITY: hidden"><FONT color=green 
face="arial black">g</FONT></DIV>
<DIV id=sDiv7 style="POSITION: absolute; VISIBILITY: hidden"><FONT color=skyblue 
face="arial black">h</FONT></DIV>
<DIV id=sDiv8 style="POSITION: absolute; VISIBILITY: hidden"><FONT color=yellow 
face="arial black">i</FONT></DIV>
<DIV id=sDiv9 style="POSITION: absolute; VISIBILITY: hidden"><FONT color=white 
face="arial black">j</FONT></DIV></DIV>

 

9.文字投影特效

<!--将以下代码加入HTML的<Body></Body>之间-->

<DIV 
style="COLOR: #0000FF; FILTER: dropshadow(color=FF0000, offx=3, offy=3, positive=1); FONT-FAMILY: Arial; FONT-SIZE: 15pt; POSITION: relative; WIDTH: 350px">
网页特效梦工厂
</DIV>


10.随机文本

<!--将以下代码加入HTML的<Body></Body>之间-->

<script Language="Javascript">
tips = new Array();
tips[0]=’所有被热烈浸透的夜晚’
tips[1]=’如此遥远的旋转’
tips[2]=’所有眼前的远去的黑暗’
tips[3]=’汇聚现在’
index = Math.floor(Math.random() * tips.length);
document.write("<CENTER>" + tips[index] + "</CENTER><P>");
</script>

 

11.上下跳动的文本

 

<script language="Javascript">
<!--
done = 0;
step = 4
function anim(yp,yk)
{
 if(document.layers) document.layers["napis"].top=yp;
 else  document.all["napis"].style.top=yp;

 if(yp>yk) step = -4
 if(yp<60) step = 4

 setTimeout(’anim(’+(yp+step)+’,’+yk+’)’, 10);
}
function start()
{
 if(done) return
 done = 1;

 if(navigator.appName=="Netscape") {
  document.napis.left=innerWidth/2 - 145;
  anim(60,innerHeight - 60)
 }
 else {
  napis.style.left=280;
  anim(60,document.body.offsetHeight - 60)
 }

}

out+=msg;
        seed--;

        var cmd="ScrollText(" + seed + ")";
        window.status=out;
        timerTwo=window.setTimeout(cmd,100);
     }
     else if (seed <= 0)
     {
         if (-seed < msg.length)
         {
            out+=msg.substring(-seed,msg.length);
            seed--;

            var cmd="ScrollText(" + seed + ")";
            window.status=out;
            timerTwo=window.setTimeout(cmd,100);
         }
         else
         {
            window.status=" ";
            timerTwo=window.setTimeout("ScrollText(100)",75);
         }
     }
}
</script>
</HEAD>
<BODY OnLoad="timerONE=window.setTimeout(’ScrollText(100)’,100);" <P>

 

13.状态栏闪字

<!--先将下列代码复制到<head></head>之间:-->
<script language="Javascript">
<!--

var yourwords = "欢迎光临艾克科技网站,这里是小秘的家。";
var speed = 200;
var control = 1;
function flash()
{
  if (control == 1)
   {
      window.status=yourwords;
      control=0;
    }  
  else
    {
      window.status="";
      control=1;
    }
  setTimeout("flash();",speed);
}
// -->
</script>

<!--再将下列代码复制到<body></body>之间:-->
<BODY onload="flash();">




热点排行