From 2e859c706da0a540b6bbcb90c2be959d2167fa81 Mon Sep 17 00:00:00 2001 From: User for running Openstreetmap-things Date: Mon, 31 Oct 2022 09:15:06 +0100 Subject: [PATCH] version as used after the move to new hardware in september 2022 (minor local changes) --- cgis/staticmap.php | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) diff --git a/cgis/staticmap.php b/cgis/staticmap.php index d8317db..4db9428 100755 --- a/cgis/staticmap.php +++ b/cgis/staticmap.php @@ -5,7 +5,7 @@ * staticMapLite 0.3.1 * * Copyright 2009 Gerhard Koch - * modded for RRZE settings - unrz191 2012 + 2016-06-02 + * modded for RRZE settings - unrz191 2012 + 2016-06-02 + 2022-10-28 * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -39,8 +39,9 @@ Class staticMapLite protected $tileSize = 256; protected $tileSrcUrl = array( 'osmorg' => 'http://osm.rrze.fau.de/tiles/{Z}/{X}/{Y}.png', 'osmde' => 'http://osm.rrze.fau.de/osmde/{Z}/{X}/{Y}.png', - 'osmorglowzoom' => 'http://osm.rrze.fau.de/lowzoom/{Z}/{X}/{Y}.png', - 'luftbilderl' => 'http://osm.rrze.fau.de/luftbilderl/{Z}/{X}/{Y}.png' + 'osmhd' => 'http://osm.rrze.fau.de/osmhd/{Z}/{X}/{Y}.png', + 'osmdehd' => 'http://osm.rrze.fau.de/osmdehd/{Z}/{X}/{Y}.png', + 'luftbilderl' => 'http://osm.rrze.fau.de/luftbilderl2016/{Z}/{X}/{Y}.png' ); protected $tileDefaultSrc = 'osmde'; @@ -114,7 +115,7 @@ Class staticMapLite { // get zoom from GET paramter $this->zoom = $_GET['zoom'] ? intval($_GET['zoom']) : 0; - if ($this->zoom > 18) $this->zoom = 18; + if ($this->zoom > 19) $this->zoom = 19; // get lat and lon from GET paramter list($this->lat, $this->lon) = explode(',', $_GET['center']); @@ -141,7 +142,12 @@ Class staticMapLite } if ($_GET['maptype']) { - if (array_key_exists($_GET['maptype'], $this->tileSrcUrl)) $this->maptype = $_GET['maptype']; + if (array_key_exists($_GET['maptype'], $this->tileSrcUrl)) { + $this->maptype = $_GET['maptype']; + if (($_GET['maptype'] == "osmhd") || ($_GET['maptype'] == "osmdehd")) { + $this->tileSize = 512; + } + } } } -- 2.25.1