JS打造鼠标爆炸链接

时间:2010-04-14 12:15:23  来源:第二电脑网  作者:第二电脑网

  第二电脑网导读:sp; var debrisnumber=40var debriscolor=new Array()debriscolor[0]="FFAAAA"debriscolor[1]="AA0000"debriscolor[2]="770000"debriscolor[3]="AA4444"debriscolor[4]="EE4422"var x_debrisposvar y_debrisposvar x,yvar x_random=new Array()var y_r...
  正文:

加入如下代码到body区域
<script>
<!-- Beginning of <a class="channel_keylink" href="java.chinaitlab.com/">http://java.chinaitlab.com/" target="_blank">Java</a>Script -

  
var debrisnumber=40
var debriscolor=new Array()
debriscolor[0]="FFAAAA"
debriscolor[1]="AA0000"
debriscolor[2]="770000"
debriscolor[3]="AA4444"
debriscolor[4]="EE4422"
var x_debrispos
var y_debrispos
var x,y
var x_random=new Array()
var y_random=new Array()
var max_explstephotoshop/ target=_blank class=infotextkey>ps=20
var i_explsteps=0
var i_color=0
var pause=10

function checkbrowser() {
    i_explsteps=0
    x_debrispos=x
    y_debrispos=y
    for (i=0;i<=debrisnumber;i++) {
        x_random[i]=Math.ceil(40*Math.random())-20
        y_random[i]=Math.ceil(40*Math.random())-20
 }
 if (document.all) {
        for (i=0;i<=debrisnumber;i++) {
            var thisspan=eval("document.all.span"+i+".style")
            thisspan.visibility="VISIBLE"
   thisspan.posLeft=x_debrispos
   thisspan.posTop=y_debrispos
  }
        explode_IE()
    }
    if (document.layers) {
        for (i=0;i<=debrisnumber;i++) {
            var thisspan=eval("document.span"+i)
            thisspan.visibility="VISIBLE"
            thisspan.left=x_debrispos
            thisspan.top=y_debrispos
  }
        explode_NN()
    }
}

function explode_IE() {
 if (i_explsteps<=max_explsteps) {
  for (i=0;i<=debrisnumber;i++) {
            var thisspan=eval("document.all.span"+i+".style")
            thisspan.posLeft+=x_random[i]
            thisspan.posTop+=y_random[i]
  }
  i_explsteps++
  var timer=setTimeout("explode_IE()",pause)
 }
 else {
  for (i=0;i<=debrisnumber;i++) {
         var thisspan=eval("document.all.span"+i+".style")
         thisspan.visibility="HIDDEN"
  }
  clearTimeout(timer)
 }
}

function explode_NN() {
 if (i_explsteps<=max_explsteps) {
  for (i=0;i<=debrisnumber;i++) {
            var thisspan=eval("document.span"+i)
            thisspan.left+=x_random[i]
            thisspan.top+=y_random[i]
  }
  i_explsteps++
  var timer=setTimeout("explode_NN()",pause)
 }
 else {
  for (i=0;i<=debrisnumber;i++) {
            var thisspan=eval("document.span"+i) 《JS打造鼠标爆炸链接》由第二电脑网原创提供,转载请注明:http://www.002pc.com/master/College/Programming/JavaScript/13627.html


关键字:

关于《JS打造鼠标爆炸链接》文章的评论

站内搜索: 高级搜索

热门搜索: Windows style 系统 tr IP QQ CPU 安装 function 注册 if td