見てみたら、ソースコードがアップロードできなかったので、HTMLを貼り付けました コードをコピー コードは次のとおりです: <br>.center <br>{ <br>text-align: center; <br>height: auto; <br>} <br>.center span <br>{ <br>font-size: 50px; <br>font-weight: 900; <br>line-height: 50px; <br>} <br>.center img <br>{ <br>width: 1200px; <br>height: 580px; <br>} <br>.s_chg <br>{ <br>float: left; <br>width: 1240px; <br>height: auto; <br>margin-left:40px; <br>} <br>.s_chg img <br>{ <br>width: 240px; <br>height: 120px; <br>padding-top:10px; <br>} <br>.s_title <br>{ <br>color:Red; <br>font-size :35px; <br>font-weight:bold; <br>} <br> 1 查看全部获奖 查看一等奖获奖 查看二等奖获奖 查看三等奖获奖 开始抽奖 <br>var 時間 = 0; <br>var th = 9; <br>変数 2 = 5; <br>var f =1; <br>var max = 122; <br>変数; <br>var zhong = 新しい Array(); <br>関数 sshow() { <br>$("#i_div").show(); <br>$("#s_div").hide(); <br>} <br>function wshow(e) { <br>var s_sum; <br>switch (e) { <br>case 0: <br>s_sum = th two f; <br>休憩; <br>ケース 1: <br>s_sum = th two f; <br>休憩; <br>ケース 2: <br>s_sum = th two; <br>休憩; <br>ケース 3: <br>s_sum = th; <br>休憩; <br>} <br>if (zhong.length < s_sum) { <br>var cha = (s_sum) - (zhong.length); <br>alert("名额还差 " cha.toString() " 名"); <br>戻る; <br>} <br>$("#i_div").hide(); <br>$("#s_div").show(); <br>var sdiv = $("#s_div"); <br>sdiv.children().remove(); <br>if (e == 0 || e == 3) { <br>var html = "<br/><br/><br/><span class='s_title' >三等奖</span><br/><br/><br/>"; <br>sdiv.prepend(html); <br>for (var i = 0; i <th i>html = " <img src='Content/images/JPEG/1 (" zhong[i] ").jpg' /> ; "; <br>sdiv.prepend(html); <br>} <br>} <br>if (e == 0 || e == 2) { <br>html = "<br/><br/><br/>< ;span class='s_title'>二等奖</span><br/><br/><br/>"; <br>sdiv.prepend(html); <br>for (var i = (th); i html = " <img src='Content/images/JPEG/1 (" zhong[i] ") .jpg' /> "; <br>sdiv.prepend(html); <br>} <br>} <br>if (e == 0 || e == 1) { <br>html = "<br/><br/><br/>< ;span class='s_title'>一等奖</span><br/><br/><br/>"; <br>sdiv.prepend(html); <br>for (var i = (th two); i html = " <img src='Content/images/JPEG/1 (" zhong[i] ").jpg' /> "; <br>sdiv.prepend(html); <br>} <br>} <br>} <br>function addtime() { <br>if (time == max) <br>time =0; <br>時間=時間 1; <br>$("#chg").html(時間); <br>$("#chg_img").attr("src", "Content/images/JPEG/1 (" time ").jpg"); <br>t = setTimeout("addtime()", 20); <br>} <br>関数 stoptime() { <br>clearTimeout(t); <br>while (chkzhong() == 1) { <br>} <br>zhong.push(time); <br>$("#chg_img").attr("src", "Content/images/JPEG/1 (" time ").jpg"); <br>} <br>function chg() { <br>if (zhong.length == (th two f)) { <br>alert("抜奖名额已全,请查看"); <br>戻る; <br>} <br>if ($("#chg").attr("atg") == "0") { <br>$("#chg").attr("atg", "1" ); <br>addtime(); <br>} else { <br>$("#chg").attr("atg", "0"); <br>ストップタイム(); <br>if (zhong.length == (th )) { <br>alert("三等奖已经拍完 "); <br>戻る; <br>} <br>if (zhong.length == (th two )) { <br>alert("二等奖已经拍完 "); <br>戻る; <br>} <br>if (zhong.length == (th two f )) { <br>alert("一等奖已经拍完"); <br>戻る; <br>} <br>} <br>} <br>function chkzhong() { <br>for (var it in zhong) { <br>if (it == time) { <br>if (time == max) <br>時間 = 0 <br>時間 = 時間 1; <br>1 を返します。 <br>} else { <br>return 0; <br>} <br>} <br>} <br>