[OpenLayers-Users] Given Bounds, Calculate Zoom
Michael
mdm at yachtpc.com
Wed Jun 15 10:20:23 EDT 2011
Sure!
var trackBounds = new OpenLayers.Bounds(-127.5,39,-121.9,37); //an
area off the coast of San Francisco that I care about
. ..// make the map etc
map.zoomToExtent(trackBounds, true);
Hmmm. Wait a minute. That is a little different than the function you
are talking about. I imagine that this one uses the one you are
referencing, but that may call for confirmation.
Michael
On 6/15/2011 7:11 AM, Arnie Shore wrote:
> Eric, thanks. Certainly on point.
>
> But for those of us not yet comfortable with the syntax, a usage
> example - one line in most cases, I'd think - wd be immensely helpful.
>
> I'm still fighting it and cd use some help.
>
> AS
>
> On 6/15/2011 8:01 AM, Eric Lemoine wrote: <snip>
>>
>> <http://dev.openlayers.org/releases/OpenLayers-2.10/doc/apidocs/files/OpenLayers/Map-js.html#OpenLayers.Map.getZoomForExtent>
>>
>>
>> Cheers,
>>
> _______________________________________________
> Users mailing list
> Users at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/openlayers-users
More information about the Users
mailing list