-
Notifications
You must be signed in to change notification settings - Fork 1
/
earthquake.html
89 lines (87 loc) · 2.91 KB
/
earthquake.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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<meta http-equiv="X-UA-Compatible" content="ie=edge" />
<link rel="stylesheet" href="style.css" />
<link
rel="stylesheet"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css"
/>
<title>Earthquake Detection</title>
</head>
<body>
<nav class="navbar">
<div id="trapezoid">
<a href="index.html" class="expandHome">Home</a>
<a href="earthquake.html" class="expandHome">EarthQuake</a>
<a href="" class="expandHome">Hurricane</a>
<a href="" class="expandHome">Flood</a>
<a href="" class="expandHome">About</a>
</div>
<input
autocomplete="off"
id="search"
class="search"
type="text"
placeholder=" Search through list of quakes (e.g. Texas or 2.3)"
/>
</nav>
<div id="form" class="wrapper">
<br />
<br />
<h1>Earthquake Detection</h1>
<br />
<div class="heading">
<input type="checkbox" class="toggle" id="toggle" />
<label for="toggle">
<span class="off" id="off">Recent Quakes</span>
<span class="on" id="on">Local Quakes</span>
</label>
<br />
<br />
<div class="getRecent" id="showRecentButton">
<h2>Earthquakes that happened in the past 24 hours</h2>
<br />
<button id="getRecent">Get information about recent quakes</button>
</div>
<div class="getLocation" id="showLocationButton" style="display: none">
<h2>Earthquakes that happened near me</h2>
<br />
<button id="getLocation">Get quakes near me</button>
<br />
<br />
<div id="locating" class="loc"></div>
<div id="locating2" class="loc"></div>
<div id="coordinates" class="coordinates"></div>
<br />
<a id="map" class="map"></a>
</div>
</div>
</div>
<div id="searchTerms" class="searchTerms populate">
<div class="postRecent" id="mostRecent"></div>
<div class="postLocation" id="fetchIt"></div>
</div>
<script>
function onButton() {
showRecentButton.style.display = "none";
showLocationButton.style.display = "block";
mostRecent.style.display = "none";
fetchIt.style.display = "block";
}
function offButton() {
showRecentButton.style.display = "block";
showLocationButton.style.display = "none";
mostRecent.style.display = "block";
fetchIt.style.display = "none";
}
off.addEventListener("click", onButton);
on.addEventListener("click", offButton);
</script>
<script src="recentQuakes.js"></script>
<script src="localQuakes.js"></script>
<script src="search.js"></script>
</body>
</html>