[OpenLayers-Users] trapping zoomlevel changes

Pierre GIRAUD bluecarto at gmail.com
Fri Jun 1 02:55:14 EDT 2007


You can register an event listener on the map on the "zoomend" event :

map.events.register('zoomend', null, function() {
   alert ("zoom finished");
   // do something
});

You may also have a look at the "moveend" event that is fired every
time the map extent changes (not sure).

Regards

Pierre

On 6/1/07, bradleyspencer <brad at cubewerx.com.au> wrote:
>
>
>
>
> Hello list,
>
>
>
> I want to trap any changes to a map's zoom levels. The idea is that whenever
> the user changes the zoom level I do something depending on the zoom level
> they select.
>
>
>
> Does anybody out there know how I can do this in OpenLayers?
>
>
>
> Cheers, Brad…
>
>
>
>
>
>
>
>
> _______________________________________________
> Users mailing list
> Users at openlayers.org
> http://openlayers.org/mailman/listinfo/users
>
>



More information about the Users mailing list