當前位置:開發者網絡 >> 網頁特效 >> 計數計算 >> 內容
精彩推薦
分類最新特效
分類熱點特效
   
隨機數據顯示功能、選號器
日期:2004-06-05   人氣:   【字體: 】【收藏此文


<!-- 網頁特效代碼由[中國WEB開發者網絡:http://www.ChinaWebDev.com]提供! -->
<!-- 要實現此效果需要 1 個步驟: -->

<!-- 第 1 步: -->
<!-- 把下面的代碼加到<BODY></BODY>區域中: -->

<script language="javascript">
function Quickpick()
{
var ball

for( ball = 0; ball < 5; ball++)
{
this[ball] = parseInt((Math.random() * Math.pow(10,16)) % 49) + 1;
for(var list = 0; list < ball; list++)
{
if(this[list] == this[ball])
{
list = ball;
ball--;
}
}
}
this[ball] = parseInt((Math.random() * Math.pow(10,16)) % 42) + 1;
return this;
}



</script>
<script language="javascript">

var idx;
var powerball = new Array(6);

powerball = this.Quickpick();

document.write("<center>");
document.write("體育彩票選號器");
document.write("<hr width=400><font size=+2>");
for(idx = 0; idx < 5; idx++)
document.write(powerball[idx] + " - ")
document.write("</font><font color=#D00000 size=+2>" + powerball[idx] + "</font>");
document.write("</center>");
</script>