GetFeatureInfo Requests

Feedback


Request parameters

The main request parameters for the GetFeatureInfo operation are shown in the following table:

Table 1 Main Parameters of GetFeatureInfo Operation Request

Request parameters Whether it is required Description
VERSION=version

Yes

Request version number.

REQUEST=GetFeatureInfo

Yes

Request name.

Request GetFeatureInfo operation. The request name needs to be set to GetFeatureInfo ".

Yes

A partial copy of the

Get Map request parameter.

The VERSION and REQUEST parameters

are not included. Determine the target map of the query, that is, on which map picture to query.

QUERY_LAYERS=layer_list

Yes

A list of layers

to be queried, separated by commas.

INFO_FORMAT=output_format

Yes

The return format (MIME type) of the

feature information.

Can be an application/vnd. Ogc. WMS _ XML. , application/geojson , text/xml , text/html。

FEATURE_COUNT=number

No

Number of elements

to return information (default is 1).

With ( I , J ) as the center point, according to The request parameters BBOX, Width and Height in the GetMap operation determine the radius of the initial search range and search the specified query layer. If the result returned by the query is less than user-specified The number value will double the search radius and continue to search. If the number of query results meets the number of elements returned as required by the user, the results will be returned. Otherwise, the radius will continue to be expanded. When the search radius reaches 8 times of the initial search radius, the query is terminated, the query result is returned, and the query of the next layer is entered.

The query order of layers is consistent with the order in the layer list to be queried.

I=pixel_column

Yes

The feature's X coordinate

in pixels (0 on the leftmost side, increasing to the right).

J=pixel_row

Yes

The Y coordinate of the feature in pixels (0 on the topmost side, increasing downward).

EXCEPTIONS=exception_format

No

Exception reporting format for WMS (default is application/vnd.ogc.se_xml).

Request example

The GetFeatureInfo operation is requested as follows:

<ServiceRoot>?Version=version&REQUEST=GetFeatureInfo&<map_request_copy>& QUERY_LAYERS=layer_list&INFO_FORMAT=output_format&I=pixel_column&J=pixel_row

ServiceRoot is the URI root directory of the service. Please refer to URI settings .

For example, after the native SuperMap iServer WMS 1.3.0 service starts successfully, access GetFeatureInfo operation URI is: http://localhost:8090/iserver/services/map-world/wms130/WorldMap_Day?VERSION=1.3.0&REQUEST=GetFeatureInfo&LAYERS=0.8,0.11,0.3&STYLES=&CRS=CRS:84&BBOX=-180,-90,180,90&WIDTH=800&HEIGHT=400&FORMAT=image/png&QUERY_LAYERS=0.11&INFO_FORMAT=text/xml&I=650&J=150.

The response result of this request example is shown in the Response example .