OK, part of the problem is solved I added to the matadata:

'wms_feature_info_mime_type' "text/html"

which fix the error, but now I get back what looks like image map of the 
features which is not what I was expecting.

I currently have TEMPLATE "dummy" in my layers, do I need to create a 
real template for each layer? I thought that this was supposed to return 
GML with something like COL_NAME = col_value for each of the columns.

-Steve

Stephen Woodbridge wrote:
> Hi all,
> 
> I'm trying to WMSGetFeatureInfo but have the following problem when 
> using it with mapserver:
> 
> 
> http://example.com/cgi-bin/mapserv?map=/maps/test-900913-wms.map&&service=WMS&version=1.1.0&request=GetFeatureInfo&layers=OneMileETJ%2CLakes%2CParcels%2CRailroad%2CFMRoads%2CServiceRoads%2CStreets%2CHighways%2CInterstate%2CVoting_Precincts%2CCityLimits%2CZoning,FMRoads%2CServiceRoads%2CStreets%2CHighways%2CInterstate,Voting_Precincts,Zoning,Parcels&query_layers=OneMileETJ%2CLakes%2CParcels%2CRailroad%2CFMRoads%2CServiceRoads%2CStreets%2CHighways%2CInterstate%2CVoting_Precincts%2CCityLimits%2CZoning,FMRoads%2CServiceRoads%2CStreets%2CHighways%2CInterstate,Voting_Precincts,Zoning,Parcels&styles=%2C%2C%2C%2C%2C%2C%2C%2C%2C%2C%2C,%2C%2C%2C%2C,,,&bbox=-10739792.365943%2C3773437.912618%2C-10739165.343461%2C3774064.9351&srs=EPSG%3A900913&feature_count=10&x=217&y=267&height=525&width=525&info_format=text%2Fhtml
> 
> And I get the following:
> 
> <?xml version='1.0' encoding="ISO-8859-1" standalone="no" ?>
> <!DOCTYPE ServiceExceptionReport SYSTEM 
> "http://schemas.opengis.net/wms/1.1.0/exception_1_1_0.dtd";>
> <ServiceExceptionReport version="1.1.0">
> <ServiceException>
> msWMSFeatureInfo(): WMS server error. Unsupported INFO_FORMAT value 
> (text/html).
> </ServiceException>
> </ServiceExceptionReport>
> 
> 
> If I remove the 'info_format=text%2Fhtml' part from the url I get back:
> 
> GetFeatureInfo results:
> 
> Layer 'OneMileETJ'
>    Feature 0:
> 
> Layer 'Parcels'
>    Feature 1:
> 
> Layer 'Voting_Precincts'
>    Feature 0:
> 
> Layer 'Zoning'
>    Feature 1:
> 
> Which does not seem all that useful, but this is my first attempt, and 
> I'm probably missing something basic.
> 
> A typical mapfile LAYER entry looks like:
> 
>      LAYER
>          NAME "Parcels"
>          METADATA
>              wms_title "Parcels"
>          END
>          TRANSPARENCY ALPHA
>          STATUS ON
>          CONNECTIONTYPE postgis
>          CONNECTION "user=****** dbname=mydb_test host=localhost"
>          DATA "the_geom from (select * from parcels) as foo using 
> SRID=900913 using unique gid"
>          TYPE POLYGON
>          LABELITEM "parcel_id"
>          MAXSCALEDENOM 4000
>          TEMPLATE "dummy"
>          DUMP TRUE
>          PROJECTION
>              "init=epsg:900913"
>          END
>          CLASS
>              STYLE
>                  COLOR -1 -1 -1
>                  WIDTH 2
>                  OUTLINECOLOR 255 0 255
>              END
>              LABEL
>                  TYPE TRUETYPE
>                  FONT "arial"
>                  SIZE 7
>                  COLOR "#000000"
>                  PARTIALS FALSE
>              END
>          END
>      END
> 
> Any help would be appreciated.
>    -Steve W
> _______________________________________________
> Users mailing list
> Users@openlayers.org
> http://openlayers.org/mailman/listinfo/users

_______________________________________________
Users mailing list
Users@openlayers.org
http://openlayers.org/mailman/listinfo/users

Reply via email to