Added parsing support for lat/lng coords from device location

This commit is contained in:
laf
2015-11-16 18:50:52 -08:00
parent a6f34fdf7e
commit 7d7479b977
5 changed files with 30 additions and 6 deletions

View File

@ -78,7 +78,10 @@ if ($device['location']) {
}
}
$loc = dbFetchRow("SELECT `lat`,`lng` FROM `locations` WHERE `location`=? LIMIT 1", array($device['location']));
$loc = parse_location($device['location']);
if (!is_array($loc)) {
$loc = dbFetchRow("SELECT `lat`,`lng` FROM `locations` WHERE `location`=? LIMIT 1", array($device['location']));
}
if (is_array($loc)) {
echo '<tr>
<td>Lat / Lng</td>