[OpenLayers-Users] pb with map.getZoom

Olivier Terral olivier at geomatic.ch
Tue Jun 19 07:52:15 PDT 2012


Hi Christian,

You're doing a getZoom() just after created the map and before a zooming function, so the zoom property of the map is logically 0. 

Anyway, I think you use a wrong way of managing scale dependent size. 

Your problem seems similar to this example: http://dev.openlayers.org/releases/OpenLayers-2.11/examples/label-scale.html .

Hope this helps.

Tschuuss

Le 19 juin 2012 à 15:05, christian bleau a écrit :

> Hi, i'm just trying to use OL and I meet a problem with map.getZoom here's url of my test. for adapt an size of an OpenLayers.Layer.Vector and an externalGraphic I call a var zoom with map.getZoom line: 159 I call var z= map.getZoom(); for change the size of an image But they don't work "Error: Invalid value for  attribute height="Infinity" If I try to see the z'value Firebug give me "0" .....   Thank a lot if you have the solution I search it since two days. 
> View this message in context: pb with map.getZoom
> Sent from the OpenLayers Users mailing list archive at Nabble.com.
> _______________________________________________
> Users mailing list
> Users at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/openlayers-users

Olivier Terral


 
GEOMATIC Ingénierie SA
Société du groupe Ringier
Chemin des Croisettes 26
1066 Epalinges
www.geomatic.ch
www.thevirtualcity.ch
Tél:: +41 (21) 651 30 00
Fax: +41 (21) 651 30 09




-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/openlayers-users/attachments/20120619/c3980a72/attachment-0001.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: PastedGraphic-1.gif
Type: image/gif
Size: 5116 bytes
Desc: not available
URL: <http://lists.osgeo.org/pipermail/openlayers-users/attachments/20120619/c3980a72/attachment-0001.gif>


More information about the Users mailing list