[OpenLayers-Users] Changing Filter on a mapserver Layer

Christopher Schmidt crschmidt at metacarta.com
Thu Nov 15 21:14:01 EST 2007


On Thu, Nov 15, 2007 at 09:04:07PM -0500, Stephen Woodbridge wrote:
> Hi all,
> 
> I have a POI overlay layer, based on a mapserver layer.
> I would like to create a multiple select dropdown list of the POI 
> classes, that the user can select. Then on change I would like to change 
> the mapserver url to include the selected items and refresh the layer.
> 
> So for example, the user selects HOTEL, DINING, BANK
> 
> then the mapserver URL would need to include
> 
> POI=HOTEL,DINING,BANK
> 
> I can handle the js for the onChange, but I'm not sure how to change the 
> mapserver layer object, or how to trigger the layer to be redrawn.
> 
> Some help would be appreciated.

http://dev.openlayers.org/apidocs/files/OpenLayers/Layer/HTTPRequest-js.html#OpenLayers.Layer.HTTPRequest.mergeNewParams

http://openlayers.org/dev/examples/wmst.html

Regards,
-- 
Christopher Schmidt
MetaCarta



More information about the Users mailing list