qlcgs.js 21 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611
  1. var chi = new Array();
  2. chi[0] = "和";
  3. chi[1] = "或";
  4. chi[2] = "红蓝的类型选择出现错误!";
  5. chi[3] = "您选择的";
  6. chi[4] = "号码不足,";
  7. chi[5] = "数据分析范围,";
  8. chi[6] = "请继续选择";
  9. chi[7] = "根据七乐彩历史 ";
  10. chi[8] = "—";
  11. chi[9] = "期";
  12. chi[10] = "分析:";
  13. chi[11] = "全按";
  14. chi[12] = "跟随";
  15. chi[13] = "数量";
  16. chi[14] = "排序";
  17. chi[15] = "号码";
  18. chi[16] = "开出";
  19. chi[17] = "同时";
  20. chi[18] = "后";
  21. chi[19] = "统计:";
  22. chi[20] = "按照";
  23. chi[21] = "出现";
  24. chi[22] = "合计";
  25. chi[23] = "第";
  26. chi[24] = "看详情";
  27. chi[25] = "的数据列表:";
  28. chi[26] = "红球";
  29. chi[27] = "蓝球";
  30. for (var i = 0; i < chi.length; i++) { chi[i] = unescape(chi[i]); }
  31. var current = h2b[0];
  32. var f1 = document.getElementById("fm1");
  33. function show_num() {
  34. bulid_ri();
  35. }
  36. function check_s1() {
  37. document.getElementById("result").style.display = "none";
  38. for (var i = 1; i < 33; i++) {
  39. var zeroi = add_zero(i);
  40. document.getElementById("chk_red" + zeroi).checked = false;
  41. document.getElementById("btn_red" + zeroi).className = "bigball grey";
  42. }
  43. for (var j = 1; j < 17; j++) {
  44. var zeroj = add_zero(j);
  45. document.getElementById("btn_blue" + zeroj).className = "bigball grey";
  46. document.getElementById("cir_blue" + zeroj).checked = false;
  47. }
  48. document.getElementById("nums").value = "";
  49. }
  50. function bulid_ri() {
  51. for (var i = 0; i < h2b.length; i++) {
  52. document.getElementById("r5").options[i] = new Option(h2b[i][2], i);
  53. document.getElementById("r6").options[i] = new Option(h2b[i][2], i);
  54. }
  55. document.getElementById("r5").options[i - 1].selected = true;
  56. }
  57. function bulid_ci(type) {
  58. var obj, innerHTML, limit;
  59. innerHTML = "";
  60. limit = (type == "red") ? "1:30" : "1:30";
  61. limit = limit.split(":");
  62. for (var i = limit[0]; i <= limit[1]; i++) {
  63. innerHTML += "<input type='button' class='bigball grey' id='btn_" + type + add_zero(i) + "' name='bt_" + type + "' value='" + add_zero(i) + "' onclick='check_c1(this);'>";
  64. innerHTML += "<input type='checkbox' name='c1_" + type + "' id='chk_" + type + add_zero(i) + "' value='" + add_zero(i) + "' style='display:none'>";
  65. switch (type) {
  66. case "red": if (i % 11 == 0) innerHTML += "<br/>"; break;
  67. case "blue": if (i % 8 == 0) innerHTML += "<br/>"; break;
  68. }
  69. }
  70. obj = document.getElementById("sel_" + type);
  71. obj.innerHTML = innerHTML;
  72. }
  73. function bulid_ciradio(type) {
  74. var obj, innerHTML, limit;
  75. innerHTML = "";
  76. limit = (type == "red") ? "1:30" : "1:30"; limit = limit.split(":");
  77. for (var i = limit[0]; i <= limit[1]; i++) {
  78. innerHTML += "<input type='button' class='bigball grey' id='btn_" + type + add_zero(i) + "' name='bt_" + type + "' value='" + add_zero(i) + "' onclick='check_c1radio(this);'>";
  79. innerHTML += "<input type='radio' name='c1_" + type + "' id='cir_" + type + add_zero(i) + "' value='" + add_zero(i) + "' style='display:none' >";
  80. switch (type) {
  81. case "red": if (i % 11 == 0) innerHTML += "<br>"; break;
  82. case "blue": if (i % 8 == 0) innerHTML += "<br>"; break;
  83. }
  84. }
  85. obj = document.getElementById("sel_" + type);
  86. obj.innerHTML = innerHTML;
  87. }
  88. function check_c1(obj) {
  89. var type = get_radio(document.getElementsByName("s1"));
  90. var num = document.getElementById("nums").value.split(",").length - 1;
  91. if (type == "red") {
  92. if (document.getElementById("chk_" + type + obj.value).checked == false) {
  93. obj.className = "bigball redball";
  94. document.getElementById("chk_" + type + obj.value).checked = true;
  95. } else {
  96. obj.className = "bigball grey";
  97. document.getElementById("chk_" + type + obj.value).checked = false;
  98. }
  99. if (document.getElementById("chk_" + type + obj.value).checked) {
  100. if (document.getElementById("nums").value.search(obj.value) < 0) document.getElementById("nums").value += obj.value + ",";
  101. } else {
  102. document.getElementById("nums").value = document.getElementById("nums").value.replace(obj.value + ",", "");
  103. }
  104. }
  105. if (document.getElementById("nums").value.length > 18) {
  106. alert("最多只能选择6个红球号!");
  107. obj.className = "bigball grey";
  108. document.getElementById("nums").value = document.getElementById("nums").value.replace(obj.value + ",", "");
  109. return false;
  110. }
  111. }
  112. function check_c1radio(obj) {
  113. var type = get_radio(document.getElementsByName("s1"));
  114. if (type == "blue") {
  115. if (document.getElementById("btn_" + type + obj.value).className != "bigball redball") {
  116. for (var i = 1; i < 17; i++) {
  117. var zeroi = add_zero(i);
  118. document.getElementById("btn_" + type + zeroi).className = "bigball grey";
  119. }
  120. if (document.getElementById("cir_" + type + obj.value).checked == false) {
  121. obj.className = "bigball redball";
  122. document.getElementById("cir_" + type + obj.value).checked = true;
  123. document.getElementById("nums").value = obj.value + ",";
  124. }
  125. }
  126. }
  127. //alert(document.getElementById("nums").value);
  128. }
  129. function input_t1(obj) {
  130. var type = $("input[name='r1']:checked").val();
  131. var limit;
  132. limit = (type == "0") ? "1:30" : "1:30"; limit = limit.split(":");
  133. obj.value = obj.value.replace(/\D/gi, "");
  134. try {
  135. if (obj.value.length == 2) {
  136. if (Math.round(obj.value) >= limit[0] && Math.round(obj.value) <= limit[1]) {
  137. f1.start.focus();
  138. } else {
  139. obj.value = "";
  140. }
  141. }
  142. } catch (e) { }
  143. }
  144. function leave_t1() {
  145. var type = $("input[name='r1']:checked").val();
  146. var obj = eval("f1.t1_" + type);
  147. var num = "";
  148. for (var i = 0; i < obj.length; i++) {
  149. if (obj[i].value != "" && num.search(obj[i].value + ",") < 0) num += obj[i].value + ",";
  150. }
  151. f1.nums.value = num;
  152. //check_input();
  153. }
  154. function change_s2(str) {
  155. var obj = document.all.s3;
  156. for (var i = 0; i < obj.length; i++) { obj[i].innerHTML = (str == "or") ? chi[1] : chi[0]; }
  157. }
  158. function check_input() {
  159. var obj;
  160. var type = $("input[name='s1']:checked").val();
  161. var nums = f1.nums.value.split(",");
  162. obj = (type == "red") ? f1.c1_red : f1.c1_blue;
  163. alert(obj.length);
  164. for (var i = 0; i < obj.length; i++) {
  165. obj[i].checked = false;
  166. obj[i].nextSibling.className = "";
  167. }
  168. for (var i = 0; i < nums.length - 1; i++) {
  169. obj[Math.round(nums[i]) - 1].checked = true;
  170. obj[Math.round(nums[i]) - 1].nextSibling.className = "check_" + type;
  171. }
  172. obj = (type == "red") ? f1.t1_red : f1.t1_blue;
  173. switch (type) {
  174. case "red": for (var i = 0; i < obj.length; i++) { obj[i].value = ""; } break;
  175. case "blue": obj.value = ""; break;
  176. }
  177. switch (type) {
  178. case "red": for (var i = 0; i < nums.length - 1; i++) { obj[Math.round(i)].value = nums[i]; } break;
  179. case "blue": obj.value = nums[0]; break;
  180. }
  181. }
  182. function check_start() {
  183. var type = $("#c1").attr("class");
  184. if (type != "hide") {
  185. type = "0";
  186. } else {
  187. type = "1";
  188. }
  189. var ball = "";
  190. if (type == 0) {
  191. var items = $("input[name=" + "qxgs" + "]");
  192. for (var i = 0; i < items.length; i++) {
  193. if ($(items[i]).prop("checked"))
  194. ball = ball + $(items[i]).val().replace("\n", "").trim() + ",";
  195. }
  196. ball = ball.substr(0, ball.length - 1);
  197. } else {
  198. var items = $("input[name=" + "qxgb" + "]");
  199. for (var i = 0; i < items.length; i++) {
  200. if ($(items[i]).prop("checked"))
  201. ball = ball + $(items[i]).val().replace("\n", "").trim() + ",";
  202. }
  203. ball = ball.substr(0, ball.length - 1);
  204. }
  205. var r1 = $("input[name='r1']:checked").val();
  206. var isstart = true;
  207. if (type != "0" && type != "1") { alert(chi[2]); isstart = false; }
  208. if (ball == "") { alert(chi[3] + chi[4] + chi[6]); isstart = false; }
  209. if (r1 == "") { alert(chi[3] + chi[5] + chi[6]); isstart = false; }
  210. var ball_num = ball.split(",").sort();
  211. if (type == 0) {
  212. if (ball_num.length > 7) { alert("红球个数在1至7个."); isstart = false; }
  213. } else { if (ball_num.length > 1) { alert("蓝球个数只有1个."); isstart = false; } }
  214. if (isstart) {
  215. num_start();
  216. }
  217. }
  218. var result = new Array();
  219. function format_result() {
  220. for (var i = 0; i <= 30; i++) {
  221. result[i] = new Array();
  222. for (var j = 0; j <= 30; j++) {
  223. result[i][j] = "";
  224. }
  225. }
  226. }
  227. function num_start() {
  228. format_result();
  229. document.getElementById("result").style.display = "none";
  230. var type = $("#c1").attr("class");
  231. if (type != "hide") {
  232. type = "0";
  233. } else {
  234. type = "1";
  235. }
  236. var ball = "";
  237. if (type == 0) {
  238. var items = $("input[name=" + "qxgs" + "]");
  239. for (var i = 0; i < items.length; i++) {
  240. if ($(items[i]).prop("checked"))
  241. ball = ball + $(items[i]).val().replace("\n", "").trim() + ",";
  242. }
  243. ball = ball.substr(0, ball.length - 1);
  244. } else {
  245. var items = $("input[name=" + "qxgb" + "]");
  246. for (var i = 0; i < items.length; i++) {
  247. if ($(items[i]).prop("checked"))
  248. ball = ball + $(items[i]).val().replace("\n", "").trim() + ",";
  249. }
  250. ball = ball.substr(0, ball.length - 1);
  251. }
  252. var nums = ball.split(",").sort();
  253. var s2 = (type == "0") ? "or" : "and";
  254. switch (s2) {
  255. case "and": analy_start(type, 0, nums); break;
  256. case "or": for (var i = 0; i < nums.length; i++) { analy_start(type, i, ("," + nums[i]).split(",")); } break;
  257. }
  258. //iframe.location.href = "tools_count.asp?act=follow";
  259. detail = "";
  260. sort_start();
  261. show_result();
  262. }
  263. function analy_start(type, id, nums) {
  264. var isTrue = true;
  265. var num_red;
  266. var r1 = $("input[name='r1']:checked").val();
  267. var h2b_limit;
  268. switch (r1) {
  269. case "1": h2b_limit = h2b.length - 1 + ":" + 0; break;
  270. case "2": h2b_limit = 100 + ":" + 0; break;
  271. case "3": var r2 = get_select('r2'); var r3 = get_select('r3'); h2b_limit = r2 + ":" + r3; break;
  272. }
  273. h2b_limit = h2b_limit.split(":");
  274. h2b_limit[0] = Math.round(h2b_limit[0]);
  275. h2b_limit[1] = Math.round(h2b_limit[1]);
  276. for (var i = h2b_limit[0]; i > h2b_limit[1]; i--) {
  277. switch (type) {
  278. case "0":
  279. isTrue = balance_start(nums, h2b[i][0]);
  280. if (isTrue) {
  281. num_red = h2b[i - 1][0].split(",");
  282. for (var j = 0; j < num_red.length; j++) {
  283. result[id][Math.round(num_red[j])] += i + ",";
  284. }
  285. }
  286. break;
  287. case "1":
  288. isTrue = balance_start(nums, h2b[i][1]);
  289. if (isTrue) {
  290. result[id][Math.round(h2b[i - 1][1])] += i + ",";
  291. }
  292. break;
  293. }
  294. }
  295. }
  296. function balance_start(u_nums, h_nums) {
  297. var isTrue = false;
  298. for (var i = 0; i < u_nums.length; i++) {
  299. if (Math.round(u_nums[i]) > 0) {
  300. if (h_nums.search(u_nums[i]) < 0) {
  301. isTrue = false;
  302. break;
  303. } else {
  304. isTrue = true;
  305. }
  306. }
  307. }
  308. return isTrue;
  309. }
  310. function sort_start() {
  311. var type = $("#c1").attr("class");
  312. if (type != "hide") {
  313. type = "0";
  314. } else {
  315. type = "1";
  316. }
  317. var limit = (type == "0") ? "1:30" : "1:30"; limit = limit.split(":");
  318. for (var i = 0; i < result.length; i++) {
  319. for (var j = limit[0]; j <= limit[1]; j++) {
  320. result[i][0] += add_zero(result[i][j].split(",").length - 1) + "," + add_zero(j) + "||";
  321. }
  322. result[i][0] = result[i][0].split("||").sort();
  323. for (var j = 1; j < result[i][0].length; j++) {
  324. result[i][0][j] = result[i][0][j].split(",");
  325. result[i][0][j] = Math.round(result[i][0][j][1]);
  326. }
  327. result[i][0] = result[i][0].join(",");
  328. }
  329. }
  330. function show_result() {
  331. var type = $("#c1").attr("class");
  332. if (type != "hide") {
  333. type = "0";
  334. } else {
  335. type = "1";
  336. }
  337. var typelimit = (type == "0") ? "1:30" : "1:30"; typelimit = typelimit.split(":");
  338. var qiu = (type == "0") ? chi[26] : chi[27];
  339. var s2 = (type == "0") ? "or" : "and";
  340. var ball = "";
  341. if (type == 0) {
  342. var items = $("input[name=" + "qxgs" + "]");
  343. for (var i = 0; i < items.length; i++) {
  344. if ($(items[i]).prop("checked"))
  345. ball = ball + $(items[i]).val().replace("\n", "").trim() + ",";
  346. }
  347. ball = ball.substr(0, ball.length - 1);
  348. } else {
  349. var items = $("input[name=" + "qxgb" + "]");
  350. for (var i = 0; i < items.length; i++) {
  351. if ($(items[i]).prop("checked"))
  352. ball = ball + $(items[i]).val().replace("\n", "").trim() + ",";
  353. }
  354. ball = ball.substr(0, ball.length - 1);
  355. }
  356. var nums = ball.split(",").sort();
  357. var limit = (s2 == "or") ? "1:" + (nums.length) : "1:0"; limit = limit.split(":");
  358. var r1 = $("input[name='r1']:checked").val();
  359. var h2b_limit;
  360. switch (r1) {
  361. case "1": h2b_limit = h2b[h2b.length - 1][2] + ":" + h2b[0][2]; break;
  362. case "2": h2b_limit = h2b[99][2] + ":" + h2b[0][2]; break;
  363. case "3": var r2 = get_select('r2'); var r3 = get_select('r3'); h2b_limit = h2b[r2][2] + ":" + h2b[r3][2]; break;
  364. }
  365. h2b_limit = h2b_limit.split(":");
  366. var innerHTML = "";
  367. innerHTML+="<div class=\"snavbox\">";
  368. innerHTML+="<div class=\"snav\">";
  369. for (var i = 0; i < nums.length; i++)
  370. {
  371. if (i==0) {
  372. innerHTML+="<a class=\"active\">跟随"+nums[i]+"</a>";
  373. }else
  374. {
  375. innerHTML += "<a class=\"\">跟随" + nums[i] + "</a>";
  376. }
  377. }
  378. innerHTML += "</div><div class=\"button\"><a class=\"left\"></a><a class=\"right\"></a></div></div>";
  379. for (var i = limit[0] - 1; i <= limit[1]; i++) {
  380. show_concrete(i, "id");
  381. }
  382. detail += "</div>";
  383. innerHTML += detail;
  384. $("#result").html(innerHTML);
  385. $("#result").show();
  386. $(".snav").find("a").click(function () {
  387. $(".snav").find("a").attr('class', '');
  388. $(".num-result").find("ul").attr('class', 'hide');
  389. $(".swiper").find("section").attr('class', 'hide');
  390. $(this).attr('class', 'active');
  391. $(".swiper").find("section").eq($(this).index()).attr('class', '');
  392. $(".num-result").find("ul").eq($(this).index()).attr('class', '');
  393. });
  394. $(".snav").find("a").click(function () {
  395. $(".snav").find("a").attr('class', '');
  396. $(".ssq-gs").find("ul").attr('class', 'hide');
  397. $(this).attr('class', 'active');
  398. $(".snav").offset({ left: "4rem" });
  399. $(".ssq-gs").find("ul").eq($(this).index()).attr('class', '');
  400. });
  401. $('.hidden').hide();
  402. $(".ssq-gs").find("li").click(function () {
  403. $(this).next().siblings("li").find("a").attr('class', '');
  404. $(this).find("dl").slideDown();
  405. $(this).find("a").attr('class', 'blue');
  406. $(this).siblings("li").find("dl").slideUp();
  407. });
  408. location.hash = "#href_result";
  409. }
  410. function show_type(i, type) {
  411. show_concrete(i, type);
  412. var content = detail;
  413. var n = "list" + i;
  414. $("ul[name='" + n + "']").html(content);
  415. }
  416. function show_alltype(b, e, type) {
  417. if (b == '0' && e == '0') {
  418. show_type(0, type);
  419. } else {
  420. for (var i = b; i <= e; i++) {
  421. show_type(i, type);
  422. }
  423. }
  424. }
  425. var detail="";
  426. function show_concrete(h, type) {
  427. var limit = "";
  428. var ctype = $("#c1").attr("class");
  429. if (ctype != "hide") {
  430. ctype = "0";
  431. } else {
  432. ctype = "1";
  433. }
  434. var ball = "";
  435. if (ctype == 0) {
  436. var items = $("input[name=" + "qxgs" + "]");
  437. for (var i = 0; i < items.length; i++) {
  438. if ($(items[i]).prop("checked"))
  439. ball = ball + $(items[i]).val().replace("\n", "").trim() + ",";
  440. }
  441. ball = ball.substr(0, ball.length - 1);
  442. } else {
  443. var items = $("input[name=" + "qxgb" + "]");
  444. for (var i = 0; i < items.length; i++) {
  445. if ($(items[i]).prop("checked"))
  446. ball = ball + $(items[i]).val().replace("\n", "").trim() + ",";
  447. }
  448. ball = ball.substr(0, ball.length - 1);
  449. }
  450. var nums = ball.split(",").sort();
  451. switch (ctype) {
  452. case "0": for (var j = 30; j >= 1; j--) { limit += "," + j; } break;
  453. case "1": for (var j = 30; j >= 1; j--) { limit += "," + j; } break;
  454. }
  455. if (type == "num") limit = result[h][0];
  456. limit = limit.split(",");
  457. if (h == 0) {
  458. detail += "<div class=\"ssq-gs\"><ul>"
  459. } else {
  460. detail += "<ul class=\"hide\">"
  461. }
  462. for (var j = limit.length - 1; j > 0; j--) {
  463. detail += "<li>";
  464. detail += add_zero(limit[j]);
  465. switch (ctype) {
  466. case "1":
  467. detail += (ctype == "1") ? " " + chi[12] + " " : " " + chi[12] + chi[17] + chi[21]
  468. detail += nums.join("+").substr(0, nums.join("+").length);
  469. break;
  470. default:
  471. detail += " " + chi[12] + " " + nums[h];
  472. break;
  473. }
  474. detail += chi[22] + "<span>";
  475. detail += (result[h][limit[j]].split(",").length - 1);
  476. detail += "</span>" + chi[9];
  477. detail += "<a class=\"bold\">" + chi[24] + "</a>";
  478. show_resultlist(h+1, limit.length - j)
  479. detail += info;
  480. detail += "</li>";
  481. }
  482. detail += "</ul>";
  483. }
  484. var info;
  485. function show_resultlist(i, j) {
  486. info = "";
  487. var type = $("#c1").attr("class");
  488. if (type != "hide") {
  489. type = "0";
  490. } else {
  491. type = "1";
  492. }
  493. var s2 = (type == "0") ? "or" : "and";
  494. var ball = "";
  495. if (type == 0) {
  496. var items = $("input[name=" + "qxgs" + "]");
  497. for (var y = 0; y < items.length; y++) {
  498. if ($(items[y]).prop("checked"))
  499. ball = ball + $(items[y]).val().replace("\n", "").trim() + ",";
  500. }
  501. ball = ball.substr(0, ball.length - 1);
  502. } else {
  503. var items = $("input[name=" + "qxgb" + "]");
  504. for (var y = 0; y < items.length; y++) {
  505. if ($(items[y]).prop("checked"))
  506. ball = ball + $(items[y]).val().replace("\n", "").trim() + ",";
  507. }
  508. ball = ball.substr(0, ball.length - 1);
  509. }
  510. var nums = ball.split(",").sort();
  511. var list = result[i-1][j].split(",");
  512. var temp_nums1, temp_num2;
  513. var temp_red, temp_blue, temp_orders;
  514. temp_nums1 = (i == 0) ? nums : ("," + nums[i-1]).split(",");
  515. temp_nums2 = add_zero(j);
  516. var innerHTML = "<dl>";
  517. for (var i = 0; i < list.length - 1; i++) {
  518. temp_orders = h2b[list[i]][2];
  519. temp_red = h2b[list[i]][0];
  520. temp_blue = h2b[list[i]][1];
  521. for (var j = 1; j < temp_nums1.length; j++) {
  522. switch (type) {
  523. case "0": temp_red = temp_red.replace(temp_nums1[j], "<b class=\"wred\">" + temp_nums1[j] + "</b>"); break;
  524. case "1": temp_blue = temp_blue.replace(temp_nums1[j], "<b class=\"wred\">" + temp_nums1[j] + "</b>"); break;
  525. }
  526. }
  527. innerHTML += "<dt>";
  528. innerHTML += chi[23] + " " + temp_orders + " " + chi[9] + " ";
  529. innerHTML += temp_red.split(",").join(" ") + " + " + temp_blue.split(",").join(" ");
  530. innerHTML += "</dt><dt>";
  531. temp_orders = h2b[list[i] - 1][2];
  532. temp_red = h2b[list[i] - 1][0];
  533. temp_blue = h2b[list[i] - 1][1];
  534. switch (type) {
  535. case "0": temp_red = temp_red.replace(temp_nums2, "<b class=\"wred\">" + temp_nums2 + "</b>"); break;
  536. case "1": temp_blue = temp_blue.replace(temp_nums2, "<b class=\"wblue\">" + temp_nums2 + "</b>"); break;
  537. }
  538. innerHTML += chi[23] + " " + temp_orders + " " + chi[9] + " ";
  539. innerHTML += temp_red.split(",").join(" ") + " + " + temp_blue.split(",").join(" ");
  540. innerHTML += "</dt>";
  541. }
  542. innerHTML += "</dl>";
  543. info = innerHTML;
  544. }
  545. function add_zero(vars) {
  546. var tempVars = new String(vars).split(",");
  547. for (var i = 0; i < tempVars.length; i++) {
  548. tempVars[i] = (Math.round(tempVars[i]) <= 9) ? "0" + Math.round(tempVars[i]) : tempVars[i];
  549. }
  550. return tempVars.join(",");
  551. }
  552. function get_select(obj) {
  553. var qi = $("select[name='" + obj + "'] option:selected").val();
  554. return qi;
  555. }
  556. function chinese_type(str) {
  557. switch (str) {
  558. case "0": return chi[26]; break;
  559. case "1": return chi[27]; break;
  560. }
  561. }