1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
|
<?php require_once ('../webadmin/basic_info.php');
$master_room_info = get_master_room_info_web();
?>
<!DOCTYPE html> <html dir="ltr" lang="en-US"> <head> <?php require_once ("html_head.php") ?>
<?php
if($langcode == "tc"){ $recaptcha_langcode = "zh-HK"; }else{ $recaptcha_langcode = "en"; }
?> <script src='https://www.google.com/recaptcha/api.js?hl=<?=$recaptcha_langcode?>'></script>
<script type="text/javascript"> function check_available_room(master_room_id) {
var xmlhttp;
if (window.XMLHttpRequest) {// code for IE7+, Firefox, Chrome, Opera, Safari xmlhttp = new XMLHttpRequest(); } else {// code for IE6, IE5 xmlhttp = new ActiveXObject("Microsoft.XMLHTTP"); } xmlhttp.onreadystatechange = function () { if (xmlhttp.readyState == 4 && xmlhttp.status == 200) { var result = $.trim(xmlhttp.responseText);
if(result != "1"){ alert("Not available to reserve this kind of size."); } //console.log(result); } } xmlhttp.open("POST", "_ajax.php?for=check_available_room", true); xmlhttp.setRequestHeader("Content-type", "application/x-www-form-urlencoded"); xmlhttp.send("master_room_id=" + (master_room_id) ); }
$(function () { $("#billing-form-title").on("change", function () { check_available_room($(this).val()); }); }) </script> </head>
<body class="stretched no-transition">
<?php require_once ("google_analysis.php"); ?>
<!-- Document Wrapper ============================================= --> <div id="wrapper" class="clearfix">
<!-- Header ============================================= --> <?php require_once ("html_header.php") ?>
<!-- Content ============================================= --> <section id="content">
<div class="content-wrap">
<div class="container clearfix">
<div class="heading-block center"> <h1>租用迷你倉</h1> <p>迷你倉會預留二十四小時</p> </div>
<div class="col-md-12 reserve">
<h4></h4>
<p></p>
<form class="nobottommargin" id="billing-form" name="billing-form" action="reserve_post.php" method="post">
<div class="form-process"></div>
<div class="col_half"> <label for="billing-form-companyname">單位尺碼(長x闊x高):</label> <select id="billing-form-title" name="billing-form-title" class="sm-form-control required">
<?php foreach($master_room_info as $master_room){ echo "<option value='".$master_room["master_room_id"]."'>".$master_room["size"]."</option>"; } ?> </select> </div>
<div class="col_half col_last"> <label for="billing-form-name">姓名: *</label> <input type="text" id="billing-form-name" name="billing-form-name" value="" class="sm-form-control required" placeholder="姓名" /> </div> <div class="clear"></div>
<div class="col_half"> <label for="billing-form-phone">聯絡電話: *</label> <input type="text" id="billing-form-phone" name="billing-form-phone" value="" class="sm-form-control required" placeholder="聯絡電話" /> </div>
<div class="col_half col_last"> <label for="billing-form-email">電郵: *</label> <input type="email" id="billing-form-email" name="billing-form-email" value="" class="sm-form-control required" placeholder="電郵" /> </div> <div class="clear"></div>
<div class="col_full"> <b>租用條款:</b><br /> 您在此同意條款與細則。您清楚知道您有責任準時支付所有相關費用,並提供有效的付款方式給出入易迷你倉。<br /><br /> 您的結算日為您開始搬入迷你倉的那天。您同意繳付兩個月按金及至少一個月租用費才能使用出入易迷你倉服務。通過線上繳付系統,您將會在每月的結算日自動支付儲存月費。 </div>
<div class="col_full"> <label for="billing-form-agree"><input id="billing-form-agree" name="billing-form-agree" type="checkbox" value="1" class="required" /> <span style="font-size:18px;">我同意租用條款與細則</span></label> <label for="billing-form-agree" class="error" style="display: block !important;"></label> </div>
<div class="col_full"> <label for="template-contactform-message">驗證 <small>*</small></label> <div class="g-recaptcha" data-theme="light" data-sitekey="<?=$google_recaptcha_site_key?>"></div>
</div>
<div class="col_full center"> <button class="button nomargin" type="submit" id="billing-form-submit" name="billing-form-submit" value="submit">確認</button> </div> </form>
<script type="text/javascript">
$("#billing-form").validate({ messages: { 'billing-form-agree': "請同意租用條款與細則。" }
});
</script> </div> </div>
</div>
</section><!-- #content end -->
<!-- Footer ============================================= --> <?php require_once ("html_footer.php") ?>
</div><!-- #wrapper end -->
<!-- Go To Top ============================================= --> <div id="gotoTop" class="icon-angle-up"></div>
<!-- Footer Scripts ============================================= --> <script type="text/javascript" src="../js/functions.js"></script>
</body> </html>
|