[OpenLayers-Users] Proxy problem in GetFeatureInfo - nosolution??

Arnd Wippermann arnd.wippermann at web.de
Fri Mar 26 11:52:27 EDT 2010


Hi,

You have to set "wms_feature_info_mime_type" in the WEB part of your mapfile
to allow text/html.

If you want gml response you have to set DUMP TRUE in your layer

If you use something like "./etc" or "/etc" instead of
"http://localhost/etc" for your request url, then OpenLayers should not set
OpenLayers.Proxy at the beginning of the request.


Mapfile example

WEB # 3
  ...
  METADATA
      ...
      'wms_feature_info_mime_type' 'text/html'
      ...
  END
END

LAYER
  NAME              'COUNTRY'
  GROUP             'WorldMap'
  TYPE POLYGON
  STATUS ON
  DATA              'Country.shp'

  TEMPLATE 'World4326.html'
  CLASSITEM 'POP_RATE'
  CLASS
    STYLE
      OUTLINECOLOR 100 100 100
    END
  END

  DUMP TRUE #only for wfs and wms getfeatureinfo in gml

  PROJECTION
    'init=epsg:4326'
  END

  METADATA
    ...
    'wms_include_items' 'all'
    'wms_exclude_items' 'CNTRY_NAME'

    'wfs_service'        'WFS'
    'wfs_version'        '1.0.0'
    'wfs_title'          'COUNTRY'
    'wfs_typename'       'COUNTRY'
    'gml_featureid'      'FIPS_CNTRY'
    'gml_include_items'  'all'
  END
END 

Arnd


-----Ursprüngliche Nachricht-----
Von: users-bounces at openlayers.org [mailto:users-bounces at openlayers.org] Im
Auftrag von sunny74
Gesendet: Freitag, 26. März 2010 13:01
An: users at openlayers.org
Betreff: Re: [OpenLayers-Users] Proxy problem in GetFeatureInfo -
nosolution??


Hi,

There is an update.
If I use a WFS layer on top of WMS layer I get the above errors.
But if I use only WMS and last line of code is:
window.open(url, '', this,setHTML, setHTML); Then INFO_FORMAT:
'text/plain',gives something like

GetFeatureInfo results:

Layer 'RailwayStations'
  Feature 81: 

for a particular Railway stn.What is the 81?
I don't have an idea.Why doesn't it show all the feature names and their
values?
The value i.e 81 changes when I select another station within the layer
'RailwayStations'.

If INFO_FORMAT: 'text/html' then it asks me to download a file with a long
extn but I save it as a .txt file.
It 's content:

<?xml version='1.0' encoding="ISO-8859-1" standalone="no" ?> <!DOCTYPE
ServiceExceptionReport SYSTEM
"http://schemas.opengis.net/wms/1.1.1/exception_1_1_1.dtd">
<ServiceExceptionReport version="1.1.1"> <ServiceException>
msWMSFeatureInfo(): WMS server error. Unsupported INFO_FORMAT value
(text/html).
msQueryByPoint(): Search returned no results. No matching record(s) found.
</ServiceException>
</ServiceExceptionReport>

If INFO_FORMAT:'application/vnd.ogc.gml' then it asks me to download a file
with a long extn but I save it as a .gml file.

It 's content:
<?xml version="1.0" encoding="ISO-8859-1"?>

<msGMLOutput 
	 xmlns:gml="http://www.opengis.net/gml"
	 xmlns:xlink="http://www.w3.org/1999/xlink"
	 xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
</msGMLOutput>

So in none of the cases I get the actual data.
I am totally confused.
Tell me atleast one method so that I get all the feature details.

Thanks.


--
View this message in context:
http://n2.nabble.com/Proxy-problem-in-GetFeatureInfo-no-solution-tp4802810p4
803408.html
Sent from the OpenLayers Users mailing list archive at Nabble.com.
_______________________________________________
Users mailing list
Users at openlayers.org
http://openlayers.org/mailman/listinfo/users




More information about the Users mailing list