Opened 21 years ago
Closed 15 years ago
#455 closed defect (fixed)
[WMS] GetCapabilities returns text/html asimage format
Reported by: | dmorissette | Owned by: | assefa |
---|---|---|---|
Priority: | high | Milestone: | 6.0 release |
Component: | WMS Server | Version: | 4.1 |
Severity: | normal | Keywords: | wms formats |
Cc: | mapserver@…, tomkralidis |
Description (last modified by )
Brent Fraser wrote: > > The following is likely a Mapserver issue, but Mapserver 4.0 spits out > > GetMap> > <Format>image/png</Format> > <Format>image/jpeg</Format> > <Format>text/html</Format> > <Format>image/tiff</Format> > > when asked for REQUEST=GETCAPABILITIES >
I reproduced this with the GMap demo: http://www2.dmsolutions.ca/cgi-bin/mswms_gmap?request=getcapabilities
reutnrs the following formats:
<Format>image/gif</Format> <Format>image/png</Format> <Format>image/jpeg</Format> <Format>image/wbmp</Format> <Format>application/x-shockwave-flash</Format> <Format>text/html</Format> <Format>application/x-pdf</Format> <Format>image/tiff</Format>
It must be that one of the default output formats in MapServer triggers this text/html thing which confuses some clients.
I even wonder if any/all of the non-image formats would work via the WMS interface. Each of them should be tested at least once.
For sure the text/html format didn't work for me when I tried it on the GMap WMS server.
Attachments (2)
Change History (22)
comment:2 by , 20 years ago
Milestone: | → 4.4 release |
---|
comment:3 by , 19 years ago
I think we should create the default function for 4.4 release. The default function could be somethink like msGetRasterOutputFormatMimeList (driver starts with "GD/" or "GDAL/"). Adding this would solve the immediate problem that we have here. We could then use later on the CONFIG in the map file (or other mecanism to let the user define what he wants).
comment:5 by , 19 years ago
Milestone: | 4.4 release → FUTURE |
---|
Fixed as per comment #2. I will leave this open (and set it to FUTRUE) since we will need to instaure a user defined mecahnism to be able to advertize other formats. I have created a bug for the docs to be updated (Bug 1072)
comment:7 by , 19 years ago
blocked: | → 1347 |
---|
comment:8 by , 18 years ago
I would be in favour of not re-using the name wms_format for this. E.g. you could have the situation in which you would be cascading a wms layer from a different wms server. You might want to advertize that layer in other format(s) than you retrieve it.
comment:9 by , 18 years ago
I'm not adverse to using a different metadata name for this, but it will appear on the WEB metadata, not the layer metadata. WMS formats are not per layer.
comment:10 by , 18 years ago
The idea is to use a metadata ows/wms_formats or (wms_supported_formats) at a web level that would contain a comma separated list of mime types that would be advertized if valid (valid in this case means only testing if there is an output format defined for it, so basically if it is build with that output, It will be listed) If the metadata is not present, the current behaviour, which is advertizing only gd and gdal format, will be used. Is this ok ?
comment:11 by , 18 years ago
Cc: | added |
---|
comment:14 by , 17 years ago
Milestone: | 5.0 release → FUTURE |
---|
comment:15 by , 15 years ago
Keywords: | wms formats added |
---|---|
Milestone: | FUTURE → 6.0 release |
Status: | new → assigned |
bug455-patch-2.zip contains the patch against trunk.
The metadata to use is wms_getmap_formatlist "image/png,image/jpeg" I think the same logic should be applied to the getlegendgraphic. I did not add it until others comment on it.
comment:16 by , 15 years ago
Other thing that needs to be corrected as part of this fix is the formats advertised for GetImage and GetLegndGraphic do not include AGG driver. There was a specific ticket for this that was used for the 5.4.x branch (#2957)
comment:17 by , 15 years ago
Cc: | added |
---|
this stalled after the debate we had in TO on not adding more metadata (in this case it was wms_getmap_formatlist). The patch I did in March/09 was tested by someone on the mailing list the time. I still find this a useful way to control what formats are exposed. Should we just set this bug as FUTURE and forget about it until it come back as a request?
comment:18 by , 15 years ago
Description: | modified (diff) |
---|
Are you alluding to my comments about the fact that we were abusing metadata and should find better ways to handle some stuff? (It was a comment/feeling, not a statemenet since I do not have a better alternative) Anyway, I don't remember if it was targeted specifically at this issue, but thinking about it now your wms_getmap_formatlist suggestion seems too make sense as a simple and useful fix and you have my +1.
comment:19 by , 15 years ago
I was referring to the fact that there was a discussion/proposition to have a possible object structure to manage all the metadata. I am not sure I have the exact details but there was some kind of solution proposed on it. I know it did refer directly to this item but I was hesitant to add a new metadata at the time if we were going to use a new mechanism. Great I will reactivate the patch and finish it to support also getlegendgraphic request.
comment:20 by , 15 years ago
Resolution: | → fixed |
---|---|
Status: | assigned → closed |
This was commuted before beta1 and notes added to the docs.