Commit 81fff39298a7f06c884f592c3af600efb7774f40
1 parent
13c33d2c
Exists in
master
and in
7 other branches
Resolvido #78 Incluir geocoding reverso do Google na opção de identificação
Showing
2 changed files
with
43 additions
and
0 deletions
Show diff stats
... | ... | @@ -0,0 +1,43 @@ |
1 | +<?php | |
2 | +include_once("../../ms_configura.php"); | |
3 | +include_once("../../classesphp/pega_variaveis.php"); | |
4 | +?> | |
5 | +<html> | |
6 | +<head> | |
7 | +<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=ISO-8859-1"> | |
8 | +<link rel="stylesheet" type="text/css" href="../../css/i3geo_ferramentas.css"> | |
9 | + | |
10 | +<script type="text/javascript" src="http://maps.google.com/maps?file=api&v=2&sensor=false&key=<?php echo $googleApiKey; ?>"></script> | |
11 | +<script type="text/javascript"> | |
12 | +function inicializa() | |
13 | +{ | |
14 | + var p2 = <?php echo $x;?>; | |
15 | + var p1 = <?php echo $y;?>; | |
16 | + ponto = new GLatLng(p1,p2) | |
17 | + geocoder = new GClientGeocoder(); | |
18 | + var pt1 = function(response) | |
19 | + { | |
20 | + if (!response || response.Status.code != 200) { | |
21 | + var ins = "Não foi possível encontrar o endereço. Status Code:" + response.Status.code; | |
22 | + } else { | |
23 | + place = response.Placemark[0]; | |
24 | + var ins = '<b>orig latlng:</b>' + response.name + '<br/>' | |
25 | + ins += '<b>latlng:</b>' + place.Point.coordinates[0] + "," + place.Point.coordinates[1] + '<br>' | |
26 | + ins += '<b>Status Code:</b>' + response.Status.code + '<br>' | |
27 | + ins += '<b>Status Request:</b>' + response.Status.request + '<br>' | |
28 | + ins += '<b>Address:</b>' + place.address + '<br>' | |
29 | + ins += '<b>Accuracy:</b>' + place.AddressDetails.Accuracy + '<br>' | |
30 | + ins += '<b>Country code:</b> ' + place.AddressDetails.Country.CountryNameCode; | |
31 | + ins += '<br><br>O endereço obtido é aproximado. Mais detalhes em <a href="http://nicogoeminne.googlepages.com/documentation.html" >Google</a>' | |
32 | + } | |
33 | + ins += "<br><br><a href='#' onclick='javascript:history.back(-1)'>voltar</a>" | |
34 | + document.getElementById("mapa").innerHTML = ins | |
35 | + } | |
36 | + geocoder.getLocations(ponto, pt1); | |
37 | +} | |
38 | +</script> | |
39 | + </head> | |
40 | + <body onload="inicializa()"> | |
41 | + <div id="mapa"></div> | |
42 | + </body> | |
43 | +</html> | |
0 | 44 | \ No newline at end of file | ... | ... |
menutemas/admin.db
No preview for this file type