-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmap.html
More file actions
192 lines (156 loc) · 6.72 KB
/
map.html
File metadata and controls
192 lines (156 loc) · 6.72 KB
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
<!DOCTYPE html>
<html>
<head>
<!-- Meta Information -->
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no" charset="utf-8">
<!-- Main CSS -->
<link href="css/style.css" rel="stylesheet" type="text/css" />
<!-- Map -->
<script src="js/map.js"></script>
<!-- <script async defer src="https://maps.googleapis.com/maps/api/js?key=AIzaSyAe7fjHk9SIAi6gfrcXu43lK9nzPhM5f6s"></script> -->
<script src="https://maps.googleapis.com/maps/api/js?key=AIzaSyAe7fjHk9SIAi6gfrcXu43lK9nzPhM5f6s&libraries=places"></script>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.2.0/jquery.min.js"></script>
<!-- JQuery UI -->
<script type="text/javascript" src="https://code.jquery.com/ui/1.12.1/jquery-ui.min.js"></script>
<link rel="stylesheet" href="https://ajax.googleapis.com/ajax/libs/jqueryui/1.10.1/themes/base/minified/jquery-ui.min.css"
type="text/css" />
<!-- Bootstrap -->
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js"></script>
<!-- Other Scripts -->
<script src="js/rangeslider.js"></script>
<script src="js/navbar.js"></script>
<!-- CSV to JSON -->
<script src="js/papaparse.min.js"></script>
<script src="js/jquery.csv.min.js"></script>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.1.0/jquery.min.js"></script>
<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.4.8/angular.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/tinysort/2.3.6/tinysort.min.js"></script>
<style>
body {
font-family: 'Nunito Sans';
}
myModal {
display: flex;
}
</style>
</head>
<body>
<div id="gradient" class="bg-img"></div>
<div class="container-lrg max-height">
<div class="col-12 text-center">
<!-- Big Scroll Div
<div id="scroll">
heading
<h1 class="heading nunitoHead">
SpaceShare
</h1>
<div class="ctas searchDiv">
<h4 class="subheading nunitoBox">
Lorem Ipsum
</h4>
<button onclick="scroll()">Scroll </button>
</div>
</div> -->
<div class="content" id="show-map">
<!-- <button onclick="startMap()">Search </button> -->
<div class="mapContainer" id="mapContainer">
<input id="pac-input" class="controls" type="text" placeholder="Search">
<div id="map"></div>
</div>
<!-- The Modal -->
<div id="myModal" class="modal">
<!-- Modal content -->
<div class="modal-content">
<span class="close">×</span>
<h3> Make a booking for New Farm Park Gazeebo </h3>
<form class="booking-container">
<div class="mod-div">
<label for="mod-name">Name</label>
<br>
<input type="text" name="space" id="mod-name">
</div>
<br>
<div class="mod-div">
<label for="mod-email">Email</label><br>
<input type="text" name="space" id="mod-email">
</div>
<br>
<div class="mod-div">
<label for="mod-phone">Phone no.</label><br>
<input type="text" name="space" class="mod-phone">
</div>
<br>
<div class="mod-div">
<label for="mod-date">Date</label><br>
<input type="date" class="mod-date" />
</div>
<br>
<div class="mod-div">
<label>Time</label><br>
<input list="timeslot" name="timeslot">
<datalist id="timeslot">
<option value="1PM - 2PM"></option>
<option value="2PM - 3PM"></option>
<option value="3PM - 4PM"></option>
<option value="4PM - 5PM"></option>
</datalist>
</div>
<br>
<button>
Book place
</button>
</form>
</div>
</div>
<input type="hidden" id="latitudebox" name="latitude">
<input type="hidden" id="longitudebox" name="longitude">
</div>
</div>
</div>
<script type="text/javascript">
function scrollMap() {
$('html, body').animate({
scrollTop: $("#map").offset().top
}, 1000);
}
function scroll() {
$('html, body').animate({
scrollTop: $(".content").offset().top
}, 2000);
}
$(document).ready(() => {
startMap();
})
</script>
<script>
// Get the modal
var modal = document.getElementById('myModal');
var grad = document.getElementById('gradient');
var mapContainer = document.getElementById('mapContainer');
// Get the <span> element that closes the modal
var span = document.getElementsByClassName("close")[0];
// When the user clicks on <span> (x), close the modal
span.onclick = function () {
modal.style.display = "none";
grad.style.display = "none";
}
// When the user clicks anywhere outside of the modal, close it
window.onclick = function (event) {
if (event.target == modal) {
modal.style.display = "none";
grad.style.display = "none";
}
}
</script>
<script>
function openNav() {
document.getElementById("filter-component").style.width = "250px";
document.getElementById("show-map").style.marginLeft = "250px";
}
function closeNav() {
document.getElementById("filter-component").style.width = "0";
document.getElementById("show-map").style.marginLeft = "0";
}
</script>
</body>
</html>