[OpenLayers-Dev] problem in OpenLayers.Util.pagePosition

Bart van den Eijnden (OSGIS) bartvde at osgis.nl
Tue Sep 25 07:11:30 EDT 2007


Hi list,

using 2.5RC3 I have a problem in the above mentioned function, whereas this
works fine in version 2.4. The problem is only in IE.

The error occurs in the following line of getStyle (style is null or not an
object):

var value = element.style[OpenLayers.String.camelize(style)]; 

If I change the following line (back to its 2.4 equivalent):

if(element == document.body) {

to:

if(element.offsetParent == document.body) {

it works fine again.

Best regards,
Bart

--
Bart van den Eijnden
OSGIS, Open Source GIS
http://www.osgis.nl








More information about the Dev mailing list