*/ 出自: 编程中国 http://www.bc-cn.net
*/ 作者: 史诺比 E-mail:YE_8888QQ.COM QQ:8697865
*/ 时间: 2007-11-14 编程论坛首发
*/ 声明: 尊重作者劳动,转载请保留本段文字
*/ --------------------------------------------------------------------------------------
<!DOCTYPE html PUBLIC"-//udbyygy//8697865/zh" "http://www.w3c.org/tr/html4/strict.dtd">
<html>
<head>
<title></title>
<style>
body{font-size:12px;font-family:宋体}
*{margin:0px auto;padding:0px auto;}
.a1{width:240px;height:250px;border:1px solid #000}
.aa0{margin:10px auto;text-align:center;position:relative;font-size:16px;}
.aa0 div{width:100%;color:red;}
.aa1{width:210px;height:60px;border:1px solid #888;margin:10px auto;text-align:center}
.aa2,.jj{width:100%;text-align:center;}
.aa2 span{margin:auto 10px;color:red}
button{background:#fff}
.aa1 div{width:70px;height:60px;
background:#eee;float:left;
overflow:hidden;
}
.ul{list-style-type:none}
.ul div{font-size:50px;height:auto}
</style>
<script language="javascript">
var af,aff,aff1,aff2,aff3
var aaff=0
var jjff=1
var ffjj=1
function abcde(){
af=document.getElementById("oo").offsetHeight
aff=af*10
abcde1()
}
function abcde1(){
if(aaff>aff){aaff=0;}
jjff+=0.01
if(jjff>10){jjff=10;ffjj=2}
aaff+=jjff
document.getElementById("ul1").scrollTop=aaff
document.getElementById("ul2").scrollTop=aaff
document.getElementById("ul3").scrollTop=aaff
if(ffjj==1){setTimeout("abcde1()",1)}else{abcde2()}
}
function abcde2(){
if(aaff>aff){aaff=0;}
jjff-=0.01
if(jjff<1){jjff=1;ffjj=1}
aaff+=jjff
document.getElementById("ul1").scrollTop=aaff
document.getElementById("ul2").scrollTop=aaff
document.getElementById("ul3").scrollTop=aaff
if(ffjj==2){setTimeout("abcde2()",1)}else{abcde21()}
}
function abcde21(){
if(aaff>aff){aaff=0;}
aaff++
document.getElementById("ul1").scrollTop=aaff
document.getElementById("ul2").scrollTop=aaff
document.getElementById("ul3").scrollTop=aaff
if((document.getElementById("ul1").scrollTop % af)!=0){setTimeout('abcde21()',1)}
else{
for(i=1;i<4;i++){
eval("aff"+i+"=Math.ceil(Math.random()*10)*af")
abcde22(i)
}
}
}
function abcde22(a){
if(aaff>aff){aaff=0;}
if(eval("aff"+a)>=0){
if(a==1){aff1--;var po=aff1}
if(a==2){aff2--;var po=aff2}
if(a==3){aff3--;var po=aff3}
aaff=aaff+1
document.getElementById("ul"+a).scrollTop=aaff
eval("setTimeout('abcde22("+a+")',30)")
}
}
</script>
</head>
<body><br>
<div class="a1">
<div class="aa0"><div>福彩3D选号器</div><div style="color:blue;position:absolute;top:0px;left:0px;clip:rect(8px auto auto auto)">福彩3D选号器</div></div>
<div class="aa1">
<div id="abc1">
<div class="ul" id="ul1">
<div id="oo">1</div>
<div>2</div>
<div>3</div>
<div>4</div>
<div>5</div>
<div>6</div>
<div>7</div>
<div>8</div>
<div>9</div>
<div>0</div>
<div>1</div>
</div>
</div>
<div id="abc2">
<div class="ul" id="ul2">
<div>1</div>
<div>2</div>
<div>3</div>
<div>4</div>
<div>5</div>
<div>6</div>
<div>7</div>
<div>8</div>
<div>9</div>
<div>0</div>
<div>1</div>
</div>
</div>
<div id="abc3">
<div class="ul" id="ul3">
<div>1</div>
<div>2</div>
<div>3</div>
<div>4</div>
<div>5</div>
<div>6</div>
<div>7</div>
<div>8</div>
<div>9</div>
<div>0</div>
<div>1</div>
</div>
</div>
</div>
<div class="aa2"><span>天灵灵</span><span>地灵灵</span></div>
<div style="text-align:center;margin:20px auto"><button onclick="this.disabled=true;abcde()">开始</button></div>
</div>
</body>
</html>
[此贴子已经被作者于2007-11-16 11:14:27编辑过]