[mapserver-users] [Fwd: getFeatureInfo]
Daniel Morissette
morissette at dmsolutions.ca
Tue Apr 2 07:07:54 PST 2002
Hi Doug,
Doug Nebert wrote:
>
> How do I set up a getFeatureInfo on a mapserver layer? I looked
> on the website but did not see the particular example for this.
Do you mean making a layer queryable via GetFeatureInfo WMS requests?
Simply setting a query template in your layer definition in the mapfile
makes it queryable in the WMS Capabilities, and then you can use it in a
GetFeatureInfo request.
GetFeatureInfo supports up to three INFO_FORMATs in the latest version
of MapServer depending on your configuration:
- INFO_FORMAT=text/plain - List feature ids and attibute names value in
plain text format
- INFO_FORMAT=application/vnd.ogc.gml - returns selected features in
GML format. You also have to set "DUMP TRUE" in your layer to enable
this.
- INFO_FORMAT=text/html - Uses the MapServer query template to produce
query results in HTML format. Works exactly like the traditional
mapserv CGI query templates.
> Also, is there a way to slave the "STYLE" request in a WMS getMap
> request to go to one or another mapfile section? For example, I
> have set up a current conditions weather data server with both
> a WMS and WFS interface. Since it has many hourly parameters,
> I'd like to expose many possibilities to label. One convenient
> way to do this might be have one weather layer and have STYLEs
> for each parameter that would set the label item or symbol
> differently, requiring different mapfile blocks.
> Thus one could display temperature, dewpoint, wind direction,
> etc as "styles" of weather display. Is this possible, or must
> I treat these as distinct layers?
>
SLD and STYLEs are not supported by the current version. If I properly
understood what you're trying to do, then it would seem that defining
separate layers would be your best option for now.
Best Regards,
--
------------------------------------------------------------
Daniel Morissette morissette at dmsolutions.ca
DM Solutions Group http://www.dmsolutions.ca/
------------------------------------------------------------
Don't put for tomorrow what you can do today, because if
you enjoy it today you can do it again tomorrow.
More information about the MapServer-users
mailing list