[OpenLayers-Users] Zoom bar without pan controls

Derek Watling derek at cmainfo.co.za
Tue Feb 3 07:27:28 EST 2009


I have come up with my own solution. Is there a better way of doing this?

var panZoomBar = new OpenLayers.Control.PanZoomBar();
map.addControl(panZoomBar);
for (var p = 0; p < 4; p++) {
    panZoomBar.buttons[p].style.display = 'none';        // Don't dispaly
panning buttons
}
panZoomBar.div.style.marginTop = "-50px";                // Move ZoomBar up

-- 
View this message in context: http://n2.nabble.com/Zoom-bar-without-pan-controls-tp2262405p2263026.html
Sent from the OpenLayers Users mailing list archive at Nabble.com.




More information about the Users mailing list