Feature #5887

qgis on a GetFeatureInfo use always text/plain

Added by aperi2007 - 11 months ago. Updated 7 months ago.

Status:Closed Start Date:06/27/2012
Priority:Normal Due date:
Assigned to:- % Done:

0%

Category:WMS Client
Target version:Version X - Unplanned
Platform: Resolution:invalid
Platform version: Patch supplied:No
Status info:

Description

Hi,
qgis when ask to a WMS server for a GetFeatureInfo, always ask using
INFO_FORMAT=text/plain.

This is a bug. It should request using one of the availables format from GetCapabilities.
If the getcapabilities say that is allowed only text/xml.
Qgis should use

INFO_FORMAT=text/xml.

And , if possbile , to parse it using an eventually available XSL transform (linked on the xml).


Related issues

related to Quantum GIS Desktop - Feature #6575: Print the contents of identify windows Closed 10/26/2012
duplicated by Quantum GIS Desktop - Feature #5892: Enhance the identify on WMS using GetFeatureInfo Closed 06/28/2012

History

Updated by aperi2007 - 11 months ago

I check better ths is ot a bug.
A server wms always add the text/plain as available format type .
So is impossible to have a server wms with only the text/xml.
And also asking for a text/plain always is not formally an error.
Perhaps is not the better choice, but surely is not a bug.
Also I guess should be better if qgis ask to the user what kind of format is better for that request.
I guess this should be a property of the layer.
Open a specific ticket.

Updated by Giovanni Manghi 11 months ago

  • Status changed from New to Feedback

aperi2007 - wrote:

I check better ths is ot a bug. A server wms always add the text/plain as available format type . So is impossible to have a server wms with only the text/xml. And also asking for a text/plain always is not formally an error. Perhaps is not the better choice, but surely is not a bug. Also I guess should be better if qgis ask to the user what kind of format is better for that request. I guess this should be a property of the layer. Open a specific ticket.

so this ticket should be closed?

Updated by Jürgen Fischer 11 months ago

Giovanni Manghi wrote:

so this ticket should be closed?

This could still be a feature request.

We could offer a combobox in the WMS dialog and let the user select which format to use on GetFeatureInfo later (FEATURE_COUNT is already an option that modifies the GetFeatureCount request).

Updated by aperi2007 - 11 months ago

We could offer a combobox in the WMS dialog and let the user select which format to use >on GetFeatureInfo later (FEATURE_COUNT is already an option that modifies the >GetFeatureCount request).

+1

Updated by Jürgen Fischer 11 months ago

  • Tracker changed from Bug to Feature

Updated by Jürgen Fischer 11 months ago

aperi2007 - wrote:

A server wms always add the text/plain as available format type . So is impossible to have a server wms with only the text/xml.

Currently we have two methods identifyAsText and identifyAsHtml. The former uses text/plain and the latter used text/html, text/plain or text/xml - whatever the server supports first. The identify tool used identifyAsHtml and renders the result in a webkit widget (HTML as such and other formats as HTML with pre tags around the content).

Updated by aperi2007 - 11 months ago

OGC in their doc best practice will suggest to prefer to the text/html a text/xml that will send an XML linked to an XSL transform to allow the client to produce the html page.

In case of an XML actually qgis will use identifyAsHtml and resolve the XSL transform (i guess no :) ) or use identifyAsText and will report the XML as plain text ?

Updated by Jürgen Fischer 11 months ago

aperi2007 - wrote:

OGC in their doc "best practice" will suggest to prefer to the text/html a text/xml that will send an XML linked to an XSL transform to allow the client to produce the html page.

In case of an XML actually qgis will use identifyAsHtml and resolve the XSL transform (i guess no :) ) or use identifyAsText and will report the XML as plain text ?

Right, currently it just outputs the XML in "pre" text.

But QXmlQuery looks promising. I think that might actually not be that hard.

Updated by aperi2007 - 9 months ago

I guess is useful also the GML.

I have added to the ticket
http://hub.qgis.org/issues/5892
a sample of GetFeatureInfo call that return a GML (multipart with 2 files).

Updated by Paolo Cavallini 9 months ago

  • Target version set to Version 2.0.0

Updated by Pirmin Kalberer 8 months ago

  • Target version changed from Version 2.0.0 to Version X - Unplanned

Updated by aperi2007 - 7 months ago

  • Status changed from Feedback to Closed
  • Resolution set to invalid

I close this ticket to open a new ticket with better description of what need.

Also available in: Atom PDF