dkniffin / webtrees-openstreetmap

Openstreetmap plugin for webtrees
MIT License
14 stars 4 forks source link

Problem with hardcoded lat/lon #17

Closed wtosm closed 7 years ago

wtosm commented 7 years ago

When the lat/lon are hardcoded in the Gedcom event, the marker is not displayed at the correct location.

Cause : in FactPlace.php:82 preg_match() returns 1 when there is a match and the marker is thus displayed at lat=1 and lon=1

Proposed fix : --- FactPlace.php 2016-11-21 17:23:29.251131000 +0100 +++ FactPlace-new.php 2016-11-21 14:42:35.463003000 +0100 @@ -80,11 +80,11 @@ if (!$fact->getPlace()->isEmpty()) { // First look to see if the lat/lon is hardcoded in the gedcom $gedcom_lat = preg_match("/\d LATI (.*)/", $fact->getGedcom(), $match1);

dkniffin commented 7 years ago

@wtosm Mind submitting a PR for this? I'm not sure I completely understand the solution.

dkniffin commented 7 years ago

Fixed by #18