<br><tt><font size=2>vendorParams</font></tt><font size=2 face="sans-serif">
works very well!</font>
<br><font size=2 face="sans-serif">Thanks very much</font>
<br><font size=2 face="sans-serif">Steve</font>
<br><font size=2 face="sans-serif"><br>
</font>
<p><font size=3> </font>
<p>
<br>
<br>
<br>
<table width=100%>
<tr valign=top>
<td width=40%><font size=1 face="sans-serif"><b>bartvde@osgis.nl@lists.osgeo.org</b>
</font>
<br><font size=1 face="sans-serif">Envoyé par : mapserver-users-bounces@lists.osgeo.org</font>
<p><font size=1 face="sans-serif">23/11/2009 01:56 PM</font>
<td width=59%>
<table width=100%>
<tr valign=top>
<td>
<div align=right><font size=1 face="sans-serif">A</font></div>
<td><font size=1 face="sans-serif">"Daniel Morissette" <dmorissette@mapgears.com></font>
<tr valign=top>
<td>
<div align=right><font size=1 face="sans-serif">cc</font></div>
<td><font size=1 face="sans-serif">mapserver-users <mapserver-users@lists.osgeo.org></font>
<tr valign=top>
<td>
<div align=right><font size=1 face="sans-serif">Objet</font></div>
<td><font size=1 face="sans-serif">Re: [mapserver-users] WMSgetFeatureInfo
and variable substitution</font></table>
<br>
<table>
<tr valign=top>
<td>
<td></table>
<br></table>
<br>
<br>
<br>
<br>
<br><tt><font size=2>Daniel is right.<br>
<br>
Steve, I've opened up an OpenLayers bug [1]. In the meantime you can try<br>
and use vendorParams on the GetFeatureInfo control, but you need to update<br>
the property whenever your values change.<br>
<br>
Further discussion can best be done on the OL mailing list.<br>
<br>
[1] http://trac.openlayers.org/ticket/2358<br>
<br>
Best regards,<br>
Bart<br>
<br>
> I saw your post on the openlayers list, and it seems from your<br>
> description of the problem that the SEMCDC, RCC and ORDER params are<br>
> included by OpenLayers in a GetMap request but it fails to include
them<br>
> in the corresponding GetFeatureInfo request. If that's the case then<br>
> that's an issue with OpenLayers, or with the way you configure your<br>
> queryable layer in OL. I'm not fluent enough in OL personally to tell<br>
> where the solution lies, but if the params are missing in the URL
then<br>
> the problem is definitely on the client side and not on the server.<br>
><br>
> Daniel<br>
><br>
><br>
> Steve.Toutant@inspq.qc.ca wrote:<br>
>><br>
>> Hi,<br>
>> I already posted this problem on openlayers list, but it might
be a<br>
>> mapserver issue.<br>
>><br>
>> OpenLayers.Control.WMSGetFeatureInfo doesn't use the FILTER key
in my<br>
>> mapfile. This filter is define with variables like this:<br>
>> FILTER "semcdc in (%SEMCDC%) and rss in (%RSS%) and ordre
in (%ORDRE%)"<br>
>> .<br>
>><br>
>> The getMap request is succesfull but not the GetFeatureInfo request<br>
>><br>
>> Here is the request GetFeatureInfo<br>
>> /cgi-bin/mapserv.exe?map=MYMAP<br>
>> service=WMS&version=1.1.0&request=GetFeatureInfo&layers=ecoles&query_layers=ecoles&styles=&bbox=-8820221.560815%2C5721770.182129%2C-7587445.168853%2C6361395.234705&srs=EPSG%3A900913&feature_count=3000&x=272&y=457&height=523&width=1008&info_format=text%2Fhtml<br>
>><br>
>><br>
>> Here is the response<br>
>> <?xml version='1.0' encoding="ISO-8859-1" standalone="no"
?><br>
>> <!DOCTYPE ServiceExceptionReport SYSTEM<br>
>> "http://schemas.opengis.net/wms/1.1.0/exception_1_1_0.dtd"><br>
>> <ServiceExceptionReport version="1.1.0"><br>
>> <ServiceException><br>
>> prepare_database(): Query error. Error declaring cursor: ERROR:
syntax<br>
>> error at or near "%"<br>
>> LINE 1: ...:text from ecoles WHERE (semcdc in (%SEMCDC%) ...<br>
>>
^<br>
>> With query string: DECLARE mycursor BINARY CURSOR FOR SELECT<br>
>> "taux_abs"::text,"nouv"::text,asbinary(force_collection(force_2d(geom900913)),'NDR'),id::text<br>
>> from ecoles WHERE (semcdc in (%SEMCDC%) and rss in (%RSS%) and
ordre in<br>
>> (%ORDRE%)) and (geom900913 && setSRID(<br>
>> 'BOX3D(-8493071.07981319 5795761.22549582,-8480841.15528974<br>
>> 5807991.15001926)'::BOX3D,900913) )<br>
>><br>
>> </ServiceException><br>
>> </ServiceExceptionReport><br>
>><br>
>> In OL, I have a WMS layer define like this:<br>
>> new OpenLayers.Layer.WMS('ecoles',<br>
>> '.../cgi-bin/mapserv.exe?map=MYMAP',{layers: 'ecoles', transparent:<br>
>> "true", format:"image/gif", SEMCDC:thisCDC,
RSS: thisRSS, ORDRE:<br>
>> thisOrdre},{isBaseLayer: false, visibility:<br>
>> false,singleTile:true,transitionEffect: 'resize'});<br>
>><br>
>> How should I query the layer?<br>
>> Thanks<br>
>> Steve<br>
>> /<br>
>> Steve Toutant, M. Sc./<br>
>> Analyste en géomatique<br>
>> Secteur environnement<br>
>> Direction de la santé environnementale et de la toxicologie<br>
>> Institut national de santé publique du Québec<br>
>> 945, avenue Wolfe<br>
>> Québec, Qc G1V 5B3<br>
>><br>
>> Tél.: (418) 650-5115 #5281<br>
>> Fax.: (418) 654-3144_<br>
>> __steve.toutant@inspq.qc.ca_ <mailto:steve.toutant@inspq.qc.ca>_<br>
>> __http://www.inspq.qc.ca_ <http://www.inspq.qc.ca/><br>
>><br>
>><br>
>> ------------------------------------------------------------------------<br>
>><br>
>> _______________________________________________<br>
>> mapserver-users mailing list<br>
>> mapserver-users@lists.osgeo.org<br>
>> http://lists.osgeo.org/mailman/listinfo/mapserver-users<br>
><br>
><br>
> --<br>
> Daniel Morissette<br>
> http://www.mapgears.com/<br>
> _______________________________________________<br>
> mapserver-users mailing list<br>
> mapserver-users@lists.osgeo.org<br>
> http://lists.osgeo.org/mailman/listinfo/mapserver-users<br>
><br>
<br>
<br>
_______________________________________________<br>
mapserver-users mailing list<br>
mapserver-users@lists.osgeo.org<br>
http://lists.osgeo.org/mailman/listinfo/mapserver-users<br>
</font></tt>
<br>
<br>
<br>