From 5e97cd6c605a695f4226705038cdf0211f235013 Mon Sep 17 00:00:00 2001 From: fredyrivera Date: Thu, 13 Apr 2017 19:19:50 -0500 Subject: [PATCH] correccion en georeferencia de imagen --- milfs/includes/upload.php | 2 +- milfs/mapa.php | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/milfs/includes/upload.php b/milfs/includes/upload.php index d8fd717..f01c172 100755 --- a/milfs/includes/upload.php +++ b/milfs/includes/upload.php @@ -112,7 +112,7 @@ if ( !empty($exif['GPSLongitude']) && !empty($exif['GPSLatitude']) ) { if ( $exif['GPSLatitudeRef'] == 'S') $gps_latitude = -$gps_latitude; if($gps_latitude !='') { - $resultado = "../mapa.php?lon=$gps_latitude&lat=$gps_longitude&zoom=18"; + $resultado = "../mapa.php?lon=$gps_latitude&lat=$gps_longitude&zoom=18&exif"; }else{$resultado ="";} //$resultado = "$gps_longitude $gps_latitude"; diff --git a/milfs/mapa.php b/milfs/mapa.php index 285c0f8..87dbbc6 100755 --- a/milfs/mapa.php +++ b/milfs/mapa.php @@ -27,6 +27,8 @@ var map = L.map('map') .setView([, ], ); L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png').addTo(map); + function onLocationFound(e) { var radius = e.accuracy / 2; var marker = L.marker(e.latlng,{draggable: true}).addTo(map) @@ -58,7 +60,7 @@ function onLocationError(e) { map.on('locationfound', onLocationFound); map.on('locationerror', onLocationError); - + map.locate({setView: true, maxZoom: 16}); //var lat = window.parent.document.getElementById('lat'); //var lng = window.parent.document.getElementById('lon');