@@ -88,6 +88,9 @@ |
||
| 88 | 88 | </tr> |
| 89 | 89 | <?php } ?> |
| 90 | 90 | </table> |
| 91 | -<?php else : ?> |
|
| 91 | +<?php else { |
|
| 92 | + : ?> |
|
| 92 | 93 | <span style="color: red;"><?= $geolocation['message'] ?></span> |
| 93 | -<?php endif; ?> |
|
| 94 | +<?php endif; |
|
| 95 | +} |
|
| 96 | +?> |
|
@@ -60,13 +60,15 @@ |
||
| 60 | 60 | "status" => "error", |
| 61 | 61 | "message" => "{$location} couldnt be converted to a lontitud, latitude" |
| 62 | 62 | ); |
| 63 | - else : |
|
| 63 | + else { |
|
| 64 | + : |
|
| 64 | 65 | $this->geolocation = array( |
| 65 | 66 | "latitude" => $geoArr[0]['lat'], |
| 66 | 67 | "longitude" => $geoArr[0]['lon'], |
| 67 | 68 | "status" => "success", |
| 68 | 69 | "geolocation" => $geoArr[0]['address'] |
| 69 | 70 | ); |
| 71 | + } |
|
| 70 | 72 | endif; |
| 71 | 73 | |
| 72 | 74 | return $this->geolocation; |