[mapserver-dev] GetFeatureInfo problems

Fabian Schindler fabian.schindler at eox.at
Tue Mar 5 05:31:09 PST 2013


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Steve,

> Regarding the templating, I don't think that's a bug. When nothing
> is matched no templates are rendered. Instead an error is thrown
> and the normal error handling mechanisms (using ERROR and
> optionally in this case EMPTY) are used. May not be ideal but
> that's how it works.

I assumed that when the query did not match any features at least the
Header/Footer is returned. Is there a possibility in mapscript to
react to the fact that there were no results? What do you mean by
`ERROR` and `EMPTY`? Are these internals to the mapserver template
implementation?

Regards,
Fabian


> ________________________________________ From:
> mapserver-dev-bounces at lists.osgeo.org
> [mapserver-dev-bounces at lists.osgeo.org] on behalf of Fabian
> Schindler [fabian.schindler at eox.at] Sent: Tuesday, March 05, 2013
> 4:13 AM To: mapserver-dev at lists.osgeo.org Subject: [mapserver-dev]
> GetFeatureInfo problems
> 
> Dear devs,
> 
> I just stumbled over what I think is a bug in both the templating 
> mechanism aswell as the msIO system (or the Python mapscript
> interface to it). I added a minimal map, template and script in the
> attachment.
> 
> Basically what I do is the following: - Dynamically create a map
> with one layer - Set up an html template - Add a shape (feature) to
> the layer - Dispatch a WMS 1.3 GetFeatureInfo request
> 
> When the request "hits" the feature, all is well and I get a
> correct template response. On the other hand, when I "miss" the
> feature no templates are rendered, even the header and footer are
> left out; which I consider the first bug.
> 
> The second problem is when I try to retrieve the bytes from the 
> installed stdout buffer (+content type):
> 
> msIO_stripStdoutBufferContentType: General error message. Corrupt 
> Content-Type header.
> 
> If I use `msIO_getStdoutBufferBytes()` instead, I get the
> following: 'Content-Type: text/html\r\n\r\n' so it seems that the
> header is correct, but the response content is simply missing.
> 
> I get correct (still empty) responses when I use other response
> formats like GML or text/plain.
> 
> Is there a possibility to get the correct content-type / response
> from such degenerated messages?
> 
> Regards Fabian
> 

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (GNU/Linux)
Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/

iQEcBAEBAgAGBQJRNfOdAAoJEJoaok7HgajKi5wH/16Ew+K9FiBEcNBsKMPDqYyZ
vmqj62VnsGvAzVWz9w3F7fy0HY+xvhCmvxXAlr3jUNeUZqcdUx0iQF+XQ1VQq/9S
kwhVJCa9oObNB03eu18RbTaI7Mbgr7BITveyJJoXP3vZYALIDSTq3Zy90qeIb0aQ
+65m6vtdDLKqY4yha9sZ9D3Z1FOiH8ukMVv34/EhsptiH70WjFbBu7za/sole0Ti
Tj1Aaz8Kmg3MUc/HI6ScmrGK9jpF6pPVDtYaXa8lvEGDMDJ7jsVxHCeFxDBqCdja
KxZp0Qmec4co3z0Ax9WOH4Lmb1ksl2ko2yWDKd4Hrj1trdtw5K+J/1zKxpsV3pU=
=O5cJ
-----END PGP SIGNATURE-----


More information about the mapserver-dev mailing list