2
我的OpenLayers地圖有一個問題。當我點擊地圖上的標記時,它將顯示彈出窗口,但其他標記在此彈出窗口上方仍可見。Openlayers和不可見的標記彈出
這是如何以正確的方式進行的?
fromProjection = new OpenLayers.Projection("EPSG:4326");
toProjection = new OpenLayers.Projection("EPSG:900913");
markers = new OpenLayers.Layer.Markers("Markers");
markers.events.register('mouseover', markers, function(evt) {
popup = new OpenLayers.Popup.FramedCloud("Popup",
new OpenLayers.LonLat(Tlon,Tlat).transform(fromProjection, toProjection),
null,
'<span style="z-index:99999;background:red;">sdf</span>',
null,
false);
map.addPopup(popup);
});
markers.events.register('mouseout', markers, function(evt) {popup.hide();});
map.addLayer(markers);
markers.addMarker(new OpenLayers.Marker(new OpenLayers.LonLat(Tlon,Tlat).transform(fromProjection, toProjection),icon));
請多給點信息。你是如何實現彈出窗口的?您是否可以使用框架雲彈出窗口?http://dev.openlayers.org/releases/OpenLayers-2.6/doc/apidocs/files/OpenLayers/Popup/FramedCloud-js.html – Martin
是否有我們可以查看的網址排除故障? – Kyle