引用jQuery和Luckdraw.js
<script src="http://www.jq22.com/jquery/jquery-1.10.2.js"></script> <script src="js/Luckdraw.js" type="text/javascript"></script>
设置抽奖数据
var xinm = new Array(); xinm[0] = "img/1.png" xinm[1] = "img/2.png" xinm[2] = "img/3.png" xinm[3] = "img/4.png" xinm[4] = "img/5.png" xinm[5] = "img/6.png" xinm[6] = "img/7.png" var phone = new Array(); phone[0] = "王尼玛" phone[1] = "张全蛋" phone[2] = "纸巾老撕" phone[3] = "王铁柱" phone[4] = "田二妞" phone[5] = "唐马儒" phone[6] = "张三"
Luckdraw.js中Lotterynumber为当前一次抽奖几个人
var Lotterynumber = 5; //设置单次抽奖人数