search.php 2.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110
  1. <?php
  2. include $_SERVER['DOCUMENT_ROOT'].'/common/lib/comm.php';
  3. $HEADER_LOC = 'main';
  4. $nav_title = "내차 사고이력 조회";
  5. $_SESSION['s_car_update_ing'] = null; //세션 값 삭제 : car 정보 수정 중
  6. $_SESSION['s_cd_car'] = null; //세션 값 삭제 : car key
  7. ?>
  8. <?php include("../inc/inc_header.php"); ?>
  9. <main class="pb123">
  10. <section>
  11. <div class="sub--top--visual">
  12. <div class="contents--inner">
  13. <h2>내차 사고이력 조회</h2>
  14. <p>이차조아에서 사고 이력 조회 후 최고가 내차 팔기</p>
  15. </div>
  16. </div>
  17. </section>
  18. <section>
  19. <div class="car--search--wrap">
  20. <form id="frmSearch" name="frmSearch" method="post" action="search_detail.php" enctype="multipart/form-data">
  21. <div class="car--serach--inner">
  22. <div class="desc">
  23. <h2><span>걱정없는</span> 내차 팔기</h2>
  24. <p>딜러 대면 걱정 없이 견적 후 불필요한 가격 실랑이 걱정없어요!</p>
  25. <div class="d-flex align-items-center">
  26. <input type="text" class="form-control" id="nm_number" name="nm_number" placeholder="띄어쓰기 없이 차량번호를 입력하세요 (12가 12345)" style="height:50px;"/>
  27. <button type="button" class="btn btn-primary ml15" style="height:50px;" id="btn_search_car">차량 조회</button>
  28. </div>
  29. </div>
  30. </div>
  31. </form>
  32. </div>
  33. </section>
  34. </main>
  35. <script>
  36. $(function() {
  37. $("#btn_search_car").on("click", function() {
  38. var custom_opts = {
  39. title : '',
  40. btn_close_show : false,
  41. }
  42. <?php if(empty($_SESSION['s_cd_userid'])) { ?>
  43. custom_opts.title = '회원로그인 후 이용할 수 있습니다. 로그인 페이지로 이동하시겠습니까?';
  44. custom_modal_confirm(custom_opts, function(confirm) {
  45. if(confirm) {
  46. custom_modal_confirm_close();
  47. link("/member/login.php");
  48. return false;
  49. }else {
  50. return false;
  51. }
  52. });
  53. return false;
  54. <?php } ?>
  55. var fieldlist = [["nm_number","차량번호"]];
  56. if (!fnCheckForm(fieldlist)){
  57. return false;
  58. }
  59. $("#frmSearch").submit();
  60. return false;
  61. // link("search_detail.php?")
  62. //
  63. // $("#btn_search_car").hide();
  64. // var data = $("#frmSearch").serialize();
  65. // $.ajax({
  66. // url : 'proc.php',
  67. // type: 'POST',
  68. // dataType : 'json',
  69. // data: data,
  70. // success: function(res) {
  71. // $("#btn_search_car").show();
  72. //
  73. // if(res.CODE != "0000") {
  74. // custom_opts.title = res.MSG;
  75. //
  76. // custom_modal_alert(custom_opts);
  77. // return false;
  78. // }
  79. // link("sell_step1.php?mode=Step1");
  80. // },
  81. // error:function(request,status,error){
  82. // $("#btn_search_car").show();
  83. //
  84. // alert("code:"+request.status+"\n"+"message:"+request.responseText+"\n"+"error:"+error);
  85. // }
  86. // });
  87. });
  88. });
  89. </script>
  90. <?php include("../inc/inc_footer.php"); ?>