[OpenLayers-Users] Bounding box after every pan
Phil Scadden
p.scadden at gns.cri.nz
Thu Oct 10 12:41:14 PDT 2013
> I have a web map with Google as base layer. Now I want to add WFS on top
> of it, but since the WFS will load entire data, so I need the bounding box
> after every pan/zoom so that i can pass those values to geoserver to load
> the data of only that area.
You could add a "move" event handler to the map. In that handler you can
call getextent. However, a pan or zoom will call a moveto on all
layers. I dont know what effect that will have on a WFS layer - it may
preempt you.
However, I would strongly suggest that you rethink that design a little.
You will get better performance if you use WMS for displaying the layer
and only use WFS for query/selection.
Notice: This email and any attachments are confidential.
If received in error please destroy and immediately notify us.
Do not copy or disclose the contents.
More information about the Users
mailing list