[Mapbender-users] geoserver print request wrong

Albert Polze A.Polze at mailbox.tu-berlin.de
Thu Jun 16 08:58:35 EDT 2011


Setup: mapbender: 2.7.1 ; geoserver: 2.1.0 ; Debian 6.0

Error:
2011.06.16, 13:21:51,ERROR: weldMaps2PNG: unable to load image:
http://xxx.xxx.xx.xx:xxxx/geoserver/wms?SERVICE=WMS&VERSION=1.1.1&REQUEST=GetMap&SERVICE=WMS&LAYERS=Casa%253Atest_name,Casa%253AVerkehr_poly_name,Casa%253Aexport_roi_1_name&STYLES=,,,&SRS=EPSG:4326&BBOX=-7.67,33.4547,-7.54,33.6367&WIDTH=445&HEIGHT=624&FORMAT=image/png&BGCOLOR=0xffffff&TRANSPARENT=TRUE&EXCEPTIONS=application/vnd.ogc.se_xml

---------------

Dear List,

trying to print my own wms (using printPDF) results in an print without the
layers. The frame, comments, scalebar etc. are all there. Printing the Demis
World Map works fine. 

Looking at the request there are some "mistakes" in the URL every colon
(":") is expressed with "%253A". Changing this in the URL and open it with a
browser leads to the image that I wanted.

(Geoserver uses these colons to separate layer stores from layers, but you
know this...)

Looking at this old 
http://osgeo-org.1803224.n2.nabble.com/Laden-und-Drucken-externer-Kartendienste-td2057427.html
thread  I came to the conclusion that I can solve the problem by changing
the "class_stripRequest.php". 

Im not into php... so I have no idea what to do, I tried to append this to
the file... 
function encodeLegGET(){
		$this->url = preg_replace("%253A", ":", $this->url); 
		return $this->url;
... but it didnt work.

I hope somebody can give me a hint.

best regards A.Polze

---------------

Hallo Liste,

beim versuch meinen eigenen wms zu drucken, bekam ich ein leeres *.pdf. Der
Rahmen, Kommentare, Maßstabsleiste etc. waren vorhanden. Den wms der Demis
World Map konnte ich problemlos drucken.

Das Problem liegt wohl in den Aufruf, da in der URL alle Doppelpunkte durch
"%253A" ersetzt wurden.
(Die Doppelpunkte kommen vom geoserver der damit die Layerstores von den
Layern trennt aber das ist bekannt).

Ein älterer 
http://osgeo-org.1803224.n2.nabble.com/Laden-und-Drucken-externer-Kartendienste-td2057427.html
thread  hat mich auf die Idee gebracht die "class_stripRequest.php"
anzupassen.

Dummerweise hört es bei php bei mir auf. Weil es gut aussah habe ich
folgendes an die Datei noch ergänzt
...function encodeLegGET(){
		$this->url = preg_replace("%253A", ":", $this->url); 
		return $this->url;
... wie zu erwarten war das aber blödsinn.

Ich hoffe ihr könnt mir weiterhelfen. Vllt. gibt es ja noch andere Lösungen.

Grüße A.Polze




--
View this message in context: http://osgeo-org.1803224.n2.nabble.com/geoserver-print-request-wrong-tp6482919p6482919.html
Sent from the mapbender-users mailing list archive at Nabble.com.


More information about the Mapbender_users mailing list