温馨提示:代码在线浏览功能只能做为源码浏览参考,不能展示项目的全部,如果想更进一步了解该代码请下载:Ajax实现无刷新添加和删除数据源码
当前文件路径:AjaxInsertDelete/Default2.aspx

1<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default2.aspx.cs" Inherits="Default2" %> 2
3
<html> 4
<head> 5
<title>0、1数字下落</title> 6
<meta http-equiv="Content-Type" content="text/html; charset=gb2312"> 7
</head> 8
<body bgcolor=#000000> 9
<!--------------------------------> 10
<script language="JavaScript"> 11
<!-- 12
if (document.all){ 13
Cols=10; 14
Cl=24;//Space's are included so real length is 48! 15
Cs=100; 16
Ts=10; 17
Tc='#008800'; 18
Tc1='#00ff00'; 19
MnS=5; 20
MxS=30; 21
I=Cs; 22
Sp=new Array();S=new Array();Y=new Array(); 23
C=new Array();M=new Array();B=new Array(); 24
RC=new Array();E=new Array();Tcc=new Array(0,1); 25
document.write("<div id='Container' style='position:absolute;top:0;left:-"+Cs+"'>"); 26
document.write("<div style='position:relative'>"); 27
for(i=0; i < Cols; i++){ 28
S[i]=I+=Cs; 29
document.write("<div id='A' style='position:absolute;top:0;font-family:Arial;font-size:" 30
+Ts+"px;left:"+S[i]+";width:"+Ts+"px;height:0px;color:"+Tc+";visibility:hidden'></div>"); 31
} 32
document.write("</div></div>"); 33
34
for(j=0; j < Cols; j++){ 35
RC[j]=1+Math.round(Math.random()*Cl); 36
Y[j]=0; 37
Sp[j]=Math.round(MnS+Math.random()*MxS); 38
for(i=0; i < RC[j]; i++){ 39
B[i]=''; 40
C[i]=Math.round(Math.random()*1)+' '; 41
M[j]=B[0]+=C[i]; 42
} 43
} 44
function Cycle(){ 45
Container.style.top=window.document.body.scrollTop; 46
for (i=0; i < Cols; i++){ 47
var r = Math.floor(Math.random()*Tcc.length); 48
E[i] = '<font color='+Tc1+'>'+Tcc[r]+'</font>'; 49
Y[i]+=Sp[i]; 50
51
if (Y[i] > window.document.body.clientHeight){ 52
for(i2=0; i2 < Cols; i2++){ 53
RC[i2]=1+Math.round(Math.random()*Cl); 54
for(i3=0; i3 < RC[i2]; i3++){ 55
B[i3]=''; 56
C[i3]=Math.round(Math.random()*1)+' '; 57
C[Math.floor(Math.random()*i2)]=' '+' '; 58
M[i]=B[0]+=C[i3]; 59
Y[i]=-Ts*M[i].length/1.5; 60
A[i].style.visibility='visible'; 61
} 62
Sp[i]=Math.round(MnS+Math.random()*MxS); 63
} 64
} 65
A[i].style.top=Y[i]; 66
A[i].innerHTML=M[i]+' '+E[i]+' '; 67
} 68
setTimeout('Cycle()',20) 69
} 70
Cycle(); 71
} 72
// --> 73
</script> 74
<!----------------------------------> 75
</body> 76
</html> 77
78






}
