[OpenLayers-Users] getFeatureInfo request in new window + new map?

Arnd Wippermann arnd.wippermann at web.de
Wed Jan 23 14:57:08 EST 2008


Hi

It should be possible in the way you wrote. But your declaration in the
layer have to be:


layer = new OpenLayers.Layer.WMS( "OpenLayers WMS",
        "http://labs.metacarta.com/wms/vmap0", {layers: 'basic', 'ID':
'721'} );
map.addLayer(layer);

and then you get this:
http://labs.metacarta.com/wms/vmap0?LAYERS=basic&ID=721 ...
 
Mit freundlichen Grüssen

Arnd Wippermann
http://gis.ibbeck.de/ginfo/



-----Ursprüngliche Nachricht-----
Von: users-bounces at openlayers.org [mailto:users-bounces at openlayers.org] Im
Auftrag von Maria Panagou
Gesendet: Mittwoch, 23. Januar 2008 01:58
An: users at openlayers.org
Betreff: Re: [OpenLayers-Users] getFeatureInfo request in new window + new
map?



is it possible to use variable substitution in a layer creator url,in a
header template file (getfeatureinfo) such as:

 var quakes = new OpenLayers.Layer.WMS( "Óçìáíôéêïß Óåéóìïß", 
                       "http://127.0.0.1/cgi-bin/mapserv.exe?", 
                        {map: '../htdocs/mpanagou/Quakes1local.map', 
                          layers: 'Quakes',ID=[codee]
						  transparent: true},
                          {isBaseLayer:false, singletile:true, reproject:
true});

where ID is filter condition, [codee] attribute from getfeatureinfo.

in map file, layer quakes is defined by:

DATA "pos FROM (select * from public.quake_small where codee1=%ID%) as foo
using unique codee1 using SRID=4326"


in OL, the declaration of quakes as following works:

var quakes = new OpenLayers.Layer.WMS( "Óçìáíôéêïß Óåéóìïß", 
                       "http://127.0.0.1/cgi-bin/mapserv.exe?", 
                        {map: '../htdocs/mpanagou/Quakes1local.map', 
                          layers: 'Quakes',ID=721
						  transparent: true},
                          {isBaseLayer:false, singletile:true, reproject:
true});

but i want id to be set dynamically as the value of codee attribute returned
by getfeatureinforequest

thank you
--
View this message in context:
http://www.nabble.com/getFeatureInfo-request-in-new-window-%2B-new-map--tp15
009098p15032612.html
Sent from the OpenLayers Users mailing list archive at Nabble.com.

_______________________________________________
Users mailing list
Users at openlayers.org
http://openlayers.org/mailman/listinfo/users




More information about the Users mailing list