[OpenLayers-Dev] getFullRequestString: altURL deprecated in 3.0

Bart van den Eijnden (OSGIS) bartvde at osgis.nl
Mon Dec 10 08:07:21 EST 2007


I am using it to switch between WMS and WFS services. Potentially a WFS
service can run on a different URL than the WMS, and a WMS should report
this in its WMS DescribeLayer response. I use the url from that reponse to
build the WFS GetFeature url, it does work for me since the new url is based
on the passed in altURL.

    /**
     * Method: parseDescribeLayer
    */
    parseDescribeLayer: function(response) {
       var desc = new OpenLayers.Format.WMSDescribeLayer();
       var describeLayerResponse = desc.read(response.responseText);
       if (describeLayerResponse.length > 0) {
           var url =  this.map.activeLayer.getFullRequestString({
                            SERVICE: describeLayerResponse[0].owsType,
                            REQUEST: "GetFeature",
                            VERSION: "1.0.0",
                            BBOX: this.bounds.toBBOX(),
                            TYPENAME: describeLayerResponse[0].typeName
                          }, describeLayerResponse[0].owsURL);
           OpenLayers.loadURL(url, '', this, this.parseGML);
       } else {
           Ext.MessageBox.hide();
       }
    }

Best regards,
Bart

--
Bart van den Eijnden
OSGIS, Open Source GIS
http://www.osgis.nl


--------- Oorspronkelijk bericht --------
Van: Christopher Schmidt <crschmidt at metacarta.com>
Naar: Bart van den Eijnden OSGIS <bartvde at osgis.nl>
Cc: dev at openlayers.org
Onderwerp: Re: [OpenLayers-Dev] getFullRequestString: altURL deprecated in
3.0
Datum: 10/12/07 10:59

> On Mon, Dec 10, 2007 at 12:52:54PM +0100, Bart van den Eijnden (OSGIS)
wrote:
> &gt; Hi list,
> &gt; 
> &gt; I noticed in the code that the altURL parameter of
getFullRequestString
> &gt; (HTTPRequest.js) will be deprecated in 3.0.
> &gt; 
> &gt; What is the alternatively way of doing this which will be supported
in 3.0?
> 
> I think at the time, we couldn't figure out that anyone was using it,
> because by our reading, the code didn't actually work...
> 
> Are you using it? How?
> 
> Regards,
> -- 
> Christopher Schmidt
> MetaCarta
> 
> 






More information about the Dev mailing list