[mapserver-users] GetFeatureInfo
Iratxe Lejarreta
iratxe.lejarreta at axios.es
Mon Oct 5 11:09:12 PDT 2009
Hi,
When I execute the following command, Postfix return the correct result:
select * from building where ST_INTERSECTS(geom,'SRID=23030;POINT(579389.40625
4795144.78125)');
But when I execute GetFeatureInfo request in MapServer with the same
point(x,y), the response doesn't return any result:
http://localhost/cgi-
bin/test?&SERVICE=wms&VERSION=1.1.1&REQUEST=getfeatureinfo&LAYERS=mylayer&QUERY_LAYERS=mylayer&x=579389.40625&y=479511.78125&INFO_FORMAT=text/html&SRS=EPSG:23030&BBOX=532666.0,4749720.0,603151.0,4805350.0&WIDTH=512&HEIGHT=512
My map file:
MAP
NAME "TEST"
STATUS ON
SIZE 400 300
SYMBOLSET symbols.sym
EXTENT 530000 4740000 610000 4820000
UNITS METERS
SHAPEPATH "data"
IMAGECOLOR 255 255 255
FONTSET fonts.txt
WEB
IMAGEPATH "/tmp/"
IMAGEURL "/tmp/"
HEADER "../templates/test_header.html"
FOOTER "../templates/test_footer.html"
METADATA
"wms_title" "Test"
"wms_onlineresource" "http://localhost/cgi-bin/test?"
"wms_srs" "EPSG:23030"
"wms_feature_info_mime_type" "text/html"
END
END
PROJECTION
"init=epsg:23030"
END
LAYER
NAME mylayer
PROJECTION
"init=epsg:23030"
END
TYPE POLYGON
STATUS ON
DUMP TRUE
UNITS METERS
TEMPLATE "../templates/mylayer_body.html"
CONNECTIONTYPE postgis
CONNECTION "host=localhost port=5432 dbname=mydb user=postgres
password=******"
DATA "the_geom from mylayer"
METADATA
"wms_title" "mylayer"
"wms_srs" "EPSG:23030"
"wms_extent" "532666 4749720 603151 4805350"
"wms_feature_info_mime_type" "text/html"
"wms_include_items" "all"
END
TOLERANCE 5
CLASS
NAME "building"
STYLE
COLOR 200 255 0
OUTLINECOLOR 120 120 120
END
END
END
END
I tried the same map configuration with another layer but with SRS:4326 and the
result of GetFeatureInfo request is ok.
If the difference is the projection and extent, where is the error?
Thanks in advance!
--
Iratxe Lejarreta
www.axios.es
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/mapserver-users/attachments/20091005/35bfc350/attachment.htm>
More information about the MapServer-users
mailing list