[QGIS-trac] [Quantum GIS] #1346: Invalid GetMap Requests in WMS: two question marks

Quantum GIS qgis at qgis.org
Mon Oct 13 11:42:14 EDT 2008


#1346: Invalid GetMap Requests in WMS: two question marks
------------------------------------------------+---------------------------
   Reporter:  neumann                           |              Owner:  nobody       
       Type:  bug                               |             Status:  new          
   Priority:  major: does not work as expected  |          Milestone:  Version 1.0.0
  Component:  WMS                               |            Version:  HEAD         
   Keywords:                                    |   Platform_version:               
   Platform:  Debian                            |           Must_fix:  Yes          
Status_info:  0                                 |  
------------------------------------------------+---------------------------
 I just compiled the latest QGIS trunk version and ran into the problem
 that the WMS plugin now generates invalid WMS requests. Did someone change
 the WMS functionality recently?

 The problem is that it adds a second question mark in the REQUEST string,
 although the original connection string already contains a question mark.

 Here is my original WMS connection string which works fine for the
 GetCapabilities request:

 http://192.168.0.10/cgi/mapserv?map=/home/mapserverdata/orthofoto_2006.map

 Here is the connection string with two question marks that qgis generates:
 http://192.168.0.10/cgi/mapserv?map=/home/mapserverdata/orthofoto_2006.map&?SERVICE=WMS&VERSION=1.1.1&REQUEST=GetMap&BBOX=696445.925470,245312.612036,696779.574530,245536.794214&SRS=EPSG:21781&WIDTH=890&HEIGHT=599&LAYERS=orthofoto_2006_average,orthofoto_2006_bilinear&STYLES=&FORMAT=image/jpeg

 Note the second question mark before the SERVICE parameter. I think this
 is rather simple to fix in the code. Just see if a question mark is
 already present in the connection string and don't add one if it is.

 Thanks for having a look at this bug.

-- 
Ticket URL: <https://trac.osgeo.org/qgis/ticket/1346>
Quantum GIS <http://qgis.org>
Quantum GIS is an Open Source GIS viewer/editor supporting OGR, PostGIS, and GRASS formats


More information about the QGIS-trac mailing list