Commit 4bbb0024 authored by Eric - kg6wxc's avatar Eric - kg6wxc
Browse files

BugFix: map_functions.php

Ability to Hide Admin Button
parent 41275f12
......@@ -1152,6 +1152,10 @@ addControlPlaceholders(map);
map.zoomControl.setPosition('verticalcenterleft');
map.fullscreenControl.setPosition('verticalcenterleft');
EOD;
if (!isset($GLOBALS['hide_admin']) == "1") {
$Content .= <<< EOD
//admin icon (the gears)
L.Control.Admin = L.Control.extend({
options: {
......@@ -1179,7 +1183,13 @@ L.Control.Admin = L.Control.extend({
L.control.admin = function(opts) {
return new L.Control.Admin(opts);
}
/*
*admin control button
*/
L.control.admin().addTo(map);
EOD;
}
$Content .= <<< EOD
//the ruler
var rulerOptions = {position: 'verticalcenterleft',
lengthUnit: {
......@@ -1236,11 +1246,6 @@ L.control.watermark({position: 'bottomright'}).addTo(map);
*/
var contents = "";
/*
*admin control button
*/
L.control.admin().addTo(map);
EOD;
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment