[OpenLayers-Users] help with popup-location

Maren Kiehl maren.kiehl at gmx.de
Sun Aug 23 09:33:54 EDT 2009


Hi everyone,

I have a problem with the popup in my map: When I click a point a popup 
with some informations is shown. The problem is that it isn't in the 
current map size so I have to pan to the right position to be able to 
read it.
This is my popup-constructor:

popup = new OpenLayers.Popup("info",
                                    
feature.geometry.getBounds().getCenterLonLat(),
                                    new OpenLayers.Size(350,200),
                                    "test test test test",
                                    false, onPopupClose);
                     feature.popup = popup;
           map.addPopup(popup);

Which value do I have to use in the constructor for showing the popup at 
the right border of the map? At the moment the upper left corner of the 
popup is located in the center of the point which was clicked.
Could somebody help me with this problem? It's very important!

Thanks for helping me.
Bye, Maren

-------------------
Maren Kiehl
mail: maren.kiehl at gmx.de
(student bachelor of science geoinformatics)




More information about the Users mailing list