diff options
| author | Greg Roach <fisharebest@gmail.com> | 2014-02-24 07:15:58 +0000 |
|---|---|---|
| committer | Greg Roach <fisharebest@gmail.com> | 2014-02-24 07:15:58 +0000 |
| commit | 91d6d6c9583cabde91e44235a08616e45374e5ed (patch) | |
| tree | 5c9f7f9541129dad65cb2d45b5791c191501458d | |
| parent | 8629682a505895fb599b29001a7d996ec8c04d05 (diff) | |
| parent | 27a342764a6b05409ac432150204a52ff73d7cad (diff) | |
| download | webtrees-91d6d6c9583cabde91e44235a08616e45374e5ed.tar.gz webtrees-91d6d6c9583cabde91e44235a08616e45374e5ed.tar.bz2 webtrees-91d6d6c9583cabde91e44235a08616e45374e5ed.zip | |
Merge pull request #117 from mnoorenberghe/GM_MIN_ZOOM
Google maps fallout from 2af14434 - Fix references to $GM_MIN_ZOOM and getHighestIndex
| -rw-r--r-- | modules_v3/googlemap/module.php | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/modules_v3/googlemap/module.php b/modules_v3/googlemap/module.php index 6917048381..01fe7ca56f 100644 --- a/modules_v3/googlemap/module.php +++ b/modules_v3/googlemap/module.php @@ -3139,9 +3139,9 @@ class googlemap_WT_Module extends WT_Module implements WT_Module_Config, WT_Modu WT_DB::prepare("INSERT INTO `##placelocation` (pl_id, pl_parent_id, pl_level, pl_place, pl_long, pl_lati, pl_zoom, pl_icon) VALUES (?, ?, ?, ?, ?, ?, ?, ?)"); if (($_POST['LONG_CONTROL'] == '') || ($_POST['NEW_PLACE_LONG'] == '') || ($_POST['NEW_PLACE_LATI'] == '')) { - $statement->execute(array(getHighestIndex()+1, $placeid, $level, $_POST['NEW_PLACE_NAME'], null, null, $_POST['NEW_ZOOM_FACTOR'], $_POST['icon'])); + $statement->execute(array($this->getHighestIndex()+1, $placeid, $level, $_POST['NEW_PLACE_NAME'], null, null, $_POST['NEW_ZOOM_FACTOR'], $_POST['icon'])); } else { - $statement->execute(array(getHighestIndex()+1, $placeid, $level, $_POST['NEW_PLACE_NAME'], $_POST['LONG_CONTROL'][3].$_POST['NEW_PLACE_LONG'], $_POST['LATI_CONTROL'][3].$_POST['NEW_PLACE_LATI'], $_POST['NEW_ZOOM_FACTOR'], $_POST['icon'])); + $statement->execute(array($this->getHighestIndex()+1, $placeid, $level, $_POST['NEW_PLACE_NAME'], $_POST['LONG_CONTROL'][3].$_POST['NEW_PLACE_LONG'], $_POST['LATI_CONTROL'][3].$_POST['NEW_PLACE_LATI'], $_POST['NEW_ZOOM_FACTOR'], $_POST['icon'])); } // autoclose window when update successful unless debug on @@ -3277,7 +3277,7 @@ class googlemap_WT_Module extends WT_Module implements WT_Module_Config, WT_Modu $place_icon = ''; $parent_id = 0; $level = 0; - $zoomfactor = $GM_MIN_ZOOM; + $zoomfactor = $this->getSetting('GM_MIN_ZOOM'); } $selected_country = 'Countries'; $show_marker = false; @@ -4075,7 +4075,7 @@ class googlemap_WT_Module extends WT_Module implements WT_Module_Config, WT_Modu $prevLong = $place['long']; } - $highestIndex = getHighestIndex(); + $highestIndex = $this->getHighestIndex(); $default_zoom_level=array(4, 7, 10, 12); foreach ($placelistUniq as $k=>$place) { @@ -4185,7 +4185,7 @@ class googlemap_WT_Module extends WT_Module implements WT_Module_Config, WT_Modu // Strip BYTE-ORDER-MARK, if present if (!empty($lines[0]) && substr($lines[0], 0, 3)==WT_UTF8_BOM) $lines[0]=substr($lines[0], 3); asort($lines); - $highestIndex = getHighestIndex(); + $highestIndex = $this->getHighestIndex(); $placelist = array(); $j = 0; $maxLevel = 0; |
