#3635 closed enhancement (fixed)
getFeatureInfo should return wms_title in GML
Reported by: | stetou | Owned by: | mapserverbugs |
---|---|---|---|
Priority: | normal | Milestone: | |
Component: | WMS Server | Version: | 5.6 |
Severity: | normal | Keywords: | getFeatureInfo |
Cc: | assefa, tomkralidis |
Description
The GML response contains the layer name which is often useless for the user. wms_layername can be used in the METADATA but it can not have spaces since it will be an XML tag. Also, wms_layername must end with "_layer" in order to be interpreted by Openlayers read_msGMLOutput format.
I think wms_title value should be returned somehow in the GML. This string is often much more significative to the enduser than the layer name.
GetCapabilities returns the name and the wms_title. GetFeatureInfo should return that as well. Steve
Change History (11)
comment:1 by , 14 years ago
Component: | MapServer C Library → WFS Server |
---|---|
Owner: | changed from | to
comment:2 by , 14 years ago
Component: | WFS Server → WMS Server |
---|
comment:3 by , 14 years ago
Resolution: | → wontfix |
---|---|
Status: | new → closed |
comment:4 by , 14 years ago
Cc: | added |
---|
Actually, without this being part of the WMS standard for GetFeatureInfo, could MapServer embed information such as layer title and other metadata info as additional attributes of a FeatureCollection in a GML response?
Tom, Assefa, do you know enough about GML to answer this question?
comment:5 by , 14 years ago
From what I can see there are name and description elements that are optional within a FeatureCollection that can be used.
http://schemas.opengis.net/gml/2.1.2/feature.xsd http://schemas.opengis.net/gml/3.2.1/feature.xsd
We could possibly used them with I guess something like gml_description on the layer
comment:6 by , 14 years ago
MapServer's WMS GetFeatureInfo response format is not valid GML (documented in #801), so (at this point) we could really return anything we want.
As Assefa says, we could use gml:name or gml:description; GML allows these in their abstract object defs.
I propose to output gml:name
like:
<foo_layer> <gml:name>$bar</gml:name> ... </foo_layer>
where $bar is LAYER.METADATA.wms_title
. If it's set, then we output.
We could also add gml:description
(which could map to LAYER.METADATA.wms_abstract
, but we shouldn't be overloading GetFeatureInfo too much as this really should be picked up from the Capabilities XML.
Comments?
comment:7 by , 13 years ago
Committed to trunk in r11172. Added only ows:title as gml:name. As stated above, any more metadata should be fetched from GetCapabilities.
comment:8 by , 13 years ago
Resolution: | wontfix |
---|---|
Status: | closed → reopened |
comment:9 by , 13 years ago
Resolution: | → fixed |
---|---|
Status: | reopened → closed |
Unfortunately, there is not really room for this kind of information (metadata really) in a GML response.
In the OGC services model, metadata information such as layer title should be obtained by the client via the GetCapabilities call, and if a mapping from layer name to title is required then that should be done by the client itself based on the GetCapabilities data.
Note that this is not a MapServer limitation: it's the way OGC services are designed to work. This is not to say that what you want to achieve (displaying layer title in a query response) is not possible, just that it has to be handled by the client based on GetCapabilities info, and not by modifying the GetFeatureInfo response.
Closing as wontfix.