-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathindex.html
More file actions
41 lines (35 loc) · 1.21 KB
/
Copy pathindex.html
File metadata and controls
41 lines (35 loc) · 1.21 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
<html>
<head>
<title>Simple Map</title>
<link rel="stylesheet" type="text/css" href="./style.css" />
</head>
<body>
<div id="map"></div>
<p>Localização do usuário:
<label>Latitude: <span id="lat"></span></label>
<label>Longitude: <span id="lon"></span></label>
</p>
<p>Endereço do Usuário: <span id="userEndereco"></span></p>
<p>Endereço do Destino: R. Euclídes Miragaia, 25 - Centro, São José dos Campos - SP, 12245-820, Brasil</p>
<p>Distância entre os pontos: <span id="distancia"></span></p>
<p>Tempo de viagem (de carro): <span id="tempo"></span></p>
<div id="status"></div>
<div id="retorno"></div>
<script
src="https://maps.googleapis.com/maps/api/js?key=AIzaSyA32PDmcZkbv37_Jb-GU9ZOTu9OW4j1n4o"
defer></script>
<script>
async function getContent(){
try {
const response = await fetch('https://apifiap.herokuapp.com/');
const data = await response.text();
alert(data);
} catch (error) {
console.log("Errou");
}
}
getContent();
</script>
<script src="./js.js"></script>
</body>
</html>