We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 4907f21 commit 509ef44Copy full SHA for 509ef44
1 file changed
osmmap2.php
@@ -237,8 +237,9 @@
237
/* If the config include parameters get them */
238
$zoom = isset($conf['osm_conf']['left_menu']['zoom']) ? $conf['osm_conf']['left_menu']['zoom'] : 2;
239
$center = isset($conf['osm_conf']['left_menu']['center']) ? $conf['osm_conf']['left_menu']['center'] : '0,0';
240
-$center_lat = isset($center) ? explode(',', $center)[0] : 0;
241
-$center_lng = isset($center) ? explode(',', $center)[1] : 0;
+$center_arr = preg_split('/,/', $center);
+$center_lat = isset($center_arr) ? $center_arr[0] : 0;
242
+$center_lng = isset($center_arr) ? $center_arr[1] : 0;
243
244
/* If we have zoom and center coordonate, set it otherwise fallback default */
245
$zoom = isset($_GET['zoom']) ? $_GET['zoom'] : $zoom;
0 commit comments