用Javascript轻松制作抽奖系统3

上一篇 / 下一篇  2006-12-17 11:11:04 / 个人分类:Javascript

  • 文件版本: V1.0
  • 开发商: 本站原创
  • 文件来源: 本地
  • 界面语言: 简体中文
  • 授权方式: 免费
  • 运行平台: Win9X/Win2000/WinXP

function noDupNum(){
 // to remove the selected mobile phone number
 mobile.removeEleAt(randnum);
 
 // to reorganize the mobile number array!!
 var o = 0;
 for(p=0; p<mobile.length;p++){
 if(typeof mobile[p]!="undefined"){
 mobile[o] = mobile[p];
 o++;
 }
 }
 num = mobile.length-1;
 }
// method to remove the element in the array
Array.prototype.removeEleAt = function(dx)
 {
 if(isNaN(dx)||dx>this.length){return false;}
 this.splice(dx,1);
 }
// set mobile phone numbers to the table cell
function setValues(){
 document.getElementById(cellnum).value = document.getElementById("result").value ;
 cellnum++;
 }
</scrīpt>
</head>
<body>
<center>
<div> </div>
<div id="main">
 <div>
 <h1>中奖号码</h1>
 
 <p>
 <input id="result" type="text" size="30" style="height:130px;width:800px;border:2px solid red;font-size:120;" readonly/></p>
 <p>
 <input id="start" type="button" value="开始" style="border: 1px solid; border-color: #aaa 000 #000 #aaa;width:4em; background: #fc0;" ōnclick="setTimer()" />
 <input id="end" type="button" value="停" style="border: 1px solid; border-color: #aaa 000 #000 #aaa;width:4em; background: #fc0;"onclick="clearTimer();setValues();" disabled/>
</p>
 <p><strong>一等奖(10名)</strong></p>
 <table width="946" height="79" border="1">
 <tr>
 <td><input name="text36" type="text" id="36" style="height:30px;width:190px;border:1px solid red;font-size:25;" size="28" readonly/></td>
 <td><input name="text37" type="text" id="37" style="height:30px;width:190px;border:1px solid red;font-size:25;" size="20" readonly/></td>
 <td><input name="text38" type="text" id="38" style="height:30px;width:190px;border:1px solid red;font-size:25;" size="20" readonly/></td>
 <td><input name="text39" type="text" id="39" style="height:30px;width:190px;border:1px solid red;font-size:25;" size="20" readonly/></td>
 <td><input name="text40" type="text" id="40" style="height:30px;width:190px;border:1px solid red;font-size:25;" size="20" readonly/></td>
 </tr>
 <tr>
 <td><input name="text41" type="text" id="41" style="height:30px;width:190px;border:1px solid red;font-size:25;" size="28" readonly/></td>
 <td><input name="text42" type="text" id="42" style="height:30px;width:190px;border:1px solid red;font-size:25;" size="20" readonly/></td>
 <td><input name="text43" type="text" id="43" style="height:30px;width:190px;border:1px solid red;font-size:25;" size="20" readonly/></td>
 <td><input name="text44" type="text" id="44" style="height:30px;width:190px;border:1px solid red;font-size:25;" size="20" readonly/></td>
 <td><input name="text45" type="text" id="45" style="height:30px;width:190px;border:1px solid red;font-size:25;" size="20" readonly/></td>
 </tr>
 </table>
 <p>二等奖(15名)</p>
 <table width="951" height="88" border="1">
 <tr>

TAG: Javascript

 

评分:0

我来说两句

显示全部

:loveliness: :handshake :victory: :funk: :time: :kiss: :call: :hug: :lol :'( :Q :L ;P :$ :P :o :@ :D :( :)

日历

« 2008-09-21  
 123456
78910111213
14151617181920
21222324252627
282930    

我的存档

数据统计

  • 访问量: 1594
  • 日志数: 3
  • 图片数: 4
  • 商品数: 2
  • 文件数: 30
  • 书签数: 9
  • 建立时间: 2006-12-14
  • 更新时间: 2006-12-31

RSS订阅

Open Toolbar