[mapserver-users] How to query attributes via WMS
Ben Brehmer
bbrehmer at refractions.net
Mon Jul 7 12:30:28 PDT 2008
Hi Steve,
There's some documentation [1] for using Run-time substitutions. You
will need to add a regular expression for 'DATAPATTERN' in your mapfile
(DATAPATTERN '.*' will allow all substitutions). You will need to modify
your WMS call to include something as follows
"......&map.layer[layername]=DATA+the_geom+FROM+...&......" where
layername is the actual name of the layer.
[1] http://mapserver.gis.umn.edu/docs/howto/runsub
Cheers,
Ben
Steve White wrote:
>
> I’m using mapserver to overlay png tiles over a google maps interface
> and it’s working well. I have a series of shp files on the server and
> I want to build a search interface so the user can query the actual
> data. An example would be in simple terms: ‘select all data from shp
> where layer = ‘thislayer’ and field like ‘%castle%’’.
>
> Is it possible to interpret a variable if I sent it via the Url with
> the WMS call? For example, I’ll tag on &TestVar=castle to the WMS
> call. Can the map file be set up to interpret TestVar and perform a
> query against a shp file field in a given layer?
>
> Thanks,
>
> Steve
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> mapserver-users mailing list
> mapserver-users at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
More information about the MapServer-users
mailing list