-
Notifications
You must be signed in to change notification settings - Fork 3
/
contact.html
309 lines (294 loc) · 11.5 KB
/
contact.html
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
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="description" content="Your description here">
<meta name="author" content="Your Name">
<title>Contact Us</title>
<!-- Bootstrap CSS -->
<link href="css/bootstrap.min.css" rel="stylesheet" />
<link href="css/basic-template.css" rel="stylesheet" />
<!-- BootstrapValidator CSS -->
<link href="css/bootstrapValidator.min.css" rel="stylesheet"/>
<link href="css/model.css" rel="stylesheet"/>
<link href="css/mystyle.css" rel="stylesheet"/>
<link href="font-awesome/css/font-awesome.min.css" rel="stylesheet" type="text/css">
<!-- jQuery and Bootstrap JS -->
<script src="js/jquery.min.js" type="text/javascript"></script>
<script src="js/bootstrap.min.js" type="text/javascript"></script>
<!-- BootstrapValidator -->
<script src="js/bootstrapValidator.min.js" type="text/javascript"></script>
<script src="js/myScript.js" type="text/javascript"></script>
</head>
<body>
<nav class="navbar navbar-inverse navbar-fixed-top navbar-custom">
<div class="container">
<div class="navbar-header">
<button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#navbar" aria-expanded="false" aria-controls="navbar">
<span class="sr-only">Toggle navigation</span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
<a class="navbar-brand " href="Homepage.html">CleaningAtoZ</a>
</div>
<div id="navbar" class="collapse navbar-collapse">
<ul class="nav navbar-nav ">
<li><a href="Homepage.html">Home</a></li>
<li><a href="about_us.html">About</a></li>
<li class="active"><a href="contact.html">Contact</a></li>
</ul>
</div><!--/.nav-collapse -->
</div>
</nav> <br> <br> <br>
<div class="container">
<div class="starter-template">
<div class="row">
<div class="col-md-6">
<div class="panel panel-primary">
<div class="panel-heading"><h4> <center>Get a Quote</center> </h4></div> <br> <br>
<form id="registration-form" method="POST" class="form-horizontal" class="modal fade" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true" >
<div class="form-group">
<label class="col-md-2 control-label" for="Fname">First Name</label>
<div class="col-md-8">
<input type="text" class="form-control" id="Fname" name="Fname" placeholder="Your first name" />
</div>
</div>
<div class="form-group">
<label class="col-md-2 control-label" for="Lname">Last Name</label>
<div class="col-md-8">
<input type="text" class="form-control" id="Lname" name="Lname" placeholder="Your Last name" />
</div>
</div>
<div class="form-group">
<label class= "col-md-2 control-label" for="saddress">Street Address</label>
<div class="col-md-8">
<input type="text" class="form-control" id="saddress" name="saddress" placeholder="Your street address" />
</div>
</div>
<div class="form-group">
<label class= "col-md-2 control-label" for="city">City</label>
<div class="col-md-8">
<input type="text" class="form-control" id="city" name="city" placeholder="Your city name" />
</div>
</div>
<div class="form-group">
<label class= "col-md-2 control-label" for="state">State</label>
<div class="col-md-8">
<input type="text" class="form-control" id="state" name="state" placeholder="Your state" />
</div>
</div>
<div class="form-group">
<label class= "col-md-2 control-label" for="zip">Zip Code</label>
<div class="col-md-8">
<input type="text" class="form-control" id="zip" name="zip" placeholder="Your Zip please" />
</div>
</div>
<div class="form-group">
<label class= "col-md-2 control-label" for="messageb">Message</label>
<div class="col-md-8">
<textarea class="form-control" id="messageb" name="messageb" rows="7" placeholder="Your enter your requirements" /></textarea>
</div>
</div>
<div class="form-group">
<div class="col-md-6 col-md-offset-2" >
<button type="submit" class="btn btn-success" id="saveData" disabled>Submit</button>
</div>
</div>
</div>
</div>
<div class="col-md-6">
<div class="panel panel-primary">
<div class="panel-heading"><h4><center> Our Office address</center> </h4></div>
<div class="panel-body text-center">
<div>
<h4>CleaningAtoZ ltd</h4><br/>
1005 West river dr<br/>
Colonial Town <br />
Manchester NHC<br />
<i class="fa fa-phone"></i>
<abbr title="Phone">P</abbr>: (603) 123 1234 <br />
<i class="fa fa-envelope-o"></i>
<abbr title="Email">E</abbr>: <a href="mailto:[email protected]">[email protected]</a><br />
<i class="fa fa-clock-o"></i>
<abbr title="Hours">H</abbr>: Monday - Friday: 9:00 AM to 5:00 PM</p><br />
<ul class="list-unstyled list-inline list-social-icons">
<li>
<a href="www.facebook.com/cleaningatoz"><i class="fa fa-facebook-square fa-2x"></i></a>
</li>
<li>
<a href="www.linkedin.com/cleaningatoz"><i class="fa fa-linkedin-square fa-2x"></i></a>
</li>
<li>
<a href="www.twitter.com/cleaningatoz"><i class="fa fa-twitter-square fa-2x"></i></a>
</li>
<li>
<a href="www.plus.google.com/cleaningatoz"><i class="fa fa-google-plus-square fa-2x"></i></a>
</li>
</ul>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<footer>
<div class="row">
<div class="col-lg-12">
<center><p> © CleaningAtoZ 2015</p> </center>
</div>
</div>
</footer>
</div>
</body>
<script type="text/javascript"> /* Validating each and every field in contact us form */
$(document).ready(function () {
var validator = $("#registration-form").bootstrapValidator({
feedbackIcons: {
valid: "glyphicon glyphicon-ok",
invalid: "glyphicon glyphicon-remove",
validating: "glyphicon glyphicon-refresh"
},
fields : {
Fname :{
message : "Firstname is required",
validators : {
notEmpty : {
message : "Please provide an First name "
},
stringLength: {
min : 1,
max: 20,
message: "First name must be between 1 and 20 characters long"
},
Firstname: {
message: "First name is invalid"
}
}
},
Lname :{
message : "Last name is required",
validators : {
notEmpty : {
message : "Please provide an Last name"
},
stringLength: {
min : 3,
max: 20,
message: "Last name must be between 3 and 20 characters long"
},
lastname: {
message: "Last name is invalid"
}
}
},
saddress :{
message : "street address is required",
validators : {
notEmpty : {
message : "Please provide your street address"
},
stringLength: {
max: 50,
message: "Street address must be maximum of 50 characters long"
},
StreetAddress: {
message: "Street address is invalid"
}
}
},
city :{
message : "city is required",
validators : {
notEmpty : {
message : "Please provide your city name"
},
stringLength: {
min: 4,
message: "City name should be at least 4 letters"
},
cityname: {
message: "city name is invalid"
}
}
},
state:{
message : "state is required",
validators : {
notEmpty : {
message : "Please provide your state"
},
stringLength: {
min: 2,
max: 2,
message: "State must can be exactly 2 letters"
},
statemassage: {
message: "State is invalid"
}
}
},
zip:{
message : "zip is required",
validators : {
regexp: {
regexp: /^\d{5}$/,
message: 'The US zipcode must contain 5 digits'
}
}
},
messageb:{
message : "Message is required",
validators : {
notEmpty : {
message : "Please provide your requirements here"
},
stringLength: {
min: 5,
max: 500,
message: "Message lengh must be between 5 to 500 letters"
},
zmassage: {
message: " message is invalid"
}
}
},
}
});
});
</script>
<script>
$(document).ready(function () {
$('#saveData').click(function(){
var fName = $("#Fname").val(); // variable fName is declared to store first name
var lName = $("#Lname").val(); // variable lName is declared to store last name
var sAddress = $("#saddress").val(); // variable sAddess is declared to store street address
var city = $("#city").val(); // variable city is declared to store city name
var state = $("#state").val(); // variable state is declared to store state name
var zip = $("#zip").val();// variable zip is declared to store zip code
var message = $("#messageb").val();// variable message is declared to store message entered
var d = new Date(); // Variable 'd' is declared to store current date.
var currentTime = d.getUTCHours() + ":" + d.getUTCMinutes() + " UTC."; // variable city is declared to store to store city name
if(confirm("First Name: "+fName
+"\n"+"Last Name: "+lName
+"\n"+"Street Address: "+sAddress
+"\n"+"city: " +city
+"\n"+"state: " +state
+"\n"+"zip: " +zip
+"\n"+"message: "+message
+"\n"+"Hello "+ fName + ". If every thing look good press OK. If you want to make any changes presss CLOSE"
)) // This "if" condition displays the form content and conform whether entered information is correct or not.
{
alert("The message was sent" + "\n"+ "Date : " + d + "\n"+ "Time :"+ currentTime); // if OK button is pressed, a popup will be shown to say that message is send, along with time and date.
}
else
{
return false;
}
});
});
</script>
</html>