Opened 16 years ago

Closed 16 years ago

Last modified 15 years ago

#1165 closed bug (fixed)

WFS must follow WMS convention for URL (missing ? or & at end auto supplied)

Reported by: LuizDomingues53 Owned by: nobody
Priority: major: does not work as expected Milestone:
Component: Vectors Version: 0.11.0
Keywords: WFS Cc:
Must Fix for Release: Yes Platform: Windows
Platform Version: Awaiting user input: no

Description

This WFS URL (for MapServer GMap PHP Demo) doesn't work

http://localhost/cgi-bin/mapserv.exe?MAP=/ms4w/apps/gmap/htdocs/gmap75_wfs.map

because ending "&" is missing.

We expect this to work like WMS URLs: ending ? or & are optional and auto supplied by QGIS as needed.

Change History (4)

comment:1 by LuizDomingues53, 16 years ago

WFS should check URL like WMS (code follows)

// from: root/trunk/qgis/src/providers/wms/qgswmsprovider.cpp
/*************************************************************************** 
   qgswmsprovider.cpp  -  QGIS Data provider for OGC Web Map Service layers
*/
//***** Lines up to 135 missing **** Follows lines 136 to 154 ****
//
// URL can be in 3 forms:
//     1) http://xxx.xxx.xx/yyy/yyy
//     2) http://xxx.xxx.xx/yyy/yyy?
//     3) http://xxx.xxx.xx/yyy/yyy?zzz=www
//
// Prepare the URI so that we can later simply append param=value
//
    if ( !(baseUrl.contains("?")) )
    {
        baseUrl.append("?");
    }
    else if ( (baseUrl.right(1) != "?" )  &&  (baseUrl.right(1) != "&" ) )
    { 
        baseUrl.append("&");
    }

comment:2 by mhugent, 16 years ago

Resolution: fixed
Status: newclosed

Fixed in r1165. Thanks for reporting!

Marco

comment:3 by mhugent, 16 years ago

Oops, I meant r8992.

comment:4 by (none), 15 years ago

Milestone: Version 1.0.0

Milestone Version 1.0.0 deleted

Note: See TracTickets for help on using tickets.