maskForm.js 2.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172
  1. $(function () {
  2. //模拟下拉框
  3. $('.input_in .icon').on('click', function () {
  4. $('.input_in .icon >img').attr('src', 'image/image10.png');
  5. if ($('.input_in .class-list').is('.hide')) {
  6. $('.input_in .class-list').removeClass('hide');
  7. } else {
  8. $('.input_in .class-list').addClass('hide');
  9. $('.input_in .icon >img').attr('src', 'image/image6.png');
  10. }
  11. })
  12. $('.class-list ul li').on('click', function () {
  13. $('.input_in .icon >img').attr('src', 'image/image6.png');
  14. $('.input_in input').val($(this).html());
  15. $('.input_in .class-list').addClass('hide');
  16. })
  17. $('.class-list ul li').hover(
  18. function () {
  19. $(this).css({'backgroundColor': '#AAA9FB',});
  20. }, function () {
  21. $(this).css({'backgroundColor': '#CFB7FD',});
  22. }
  23. )
  24. })
  25. // $(document).ready(function () {
  26. // $(function () {
  27. // var time = 5;//倒计时总秒数量
  28. // (function () {
  29. // var intDiff = parseInt(time);//倒计时总秒数量
  30. // function timer(intDiff) {
  31. // window.setInterval(function () {
  32. // var day = 0, hour = 0, minute = 0, second = 0;//时间默认值
  33. // if (intDiff > 0) {
  34. // day = Math.floor(intDiff / (60 * 60 * 24));
  35. // hour = Math.floor(intDiff / (60 * 60)) - (day * 24);
  36. // minute = Math.floor(intDiff / 60) - (day * 24 * 60) - (hour * 60);
  37. // second = Math.floor(intDiff) - (day * 24 * 60 * 60) - (hour * 60 * 60) - (minute * 60);
  38. //
  39. // }
  40. // if (minute <= 9) minute = '0' + minute;
  41. // if (second <= 9) second = '0' + second;
  42. // if(intDiff==0){
  43. // $('.mark').addClass('hide')
  44. // console.log(55);
  45. // }
  46. // $('#day_show').html(day);
  47. // $('#hour_show').html(hour);
  48. // $('#minute_show').html(minute);
  49. // $('#second_show').html(second);
  50. // intDiff--;
  51. //
  52. //
  53. // }, 1000);
  54. //
  55. //
  56. //
  57. // };
  58. //
  59. // $(function () {
  60. // timer(intDiff);
  61. //
  62. // });
  63. // })(time)
  64. //
  65. // })
  66. // })