Hi, I get a lot of questions from people trying to remove the default PanZoom map control. I recommend this solution:
The following controls are given to the map by default: - OpenLayers.Control.Navigation<http://dev.openlayers.org/docs/files/OpenLayers/Control/Navigation-js.html#OpenLayers.Control.Navigation> - OpenLayers.Control.PanZoom<http://dev.openlayers.org/docs/files/OpenLayers/Control/PanZoom-js.html#OpenLayers.Control.PanZoom> - OpenLayers.Control.ArgParser<http://dev.openlayers.org/docs/files/OpenLayers/Control/ArgParser-js.html#OpenLayers.Control.ArgParser> - OpenLayers.Control.Attribution<http://dev.openlayers.org/docs/files/OpenLayers/Control/Attribution-js.html#OpenLayers.Control.Attribution> Instead of removing the PanZoom control, simply leave it out from the map options at construction: map = new OpenLayers.Map('your_element_id', { controls: [ new OpenLayers.Control.Navigation(), new OpenLayers.Control.ArgParser(), new OpenLayers.Control.Attribution() ] }); Jan
_______________________________________________ Users mailing list [email protected] http://openlayers.org/mailman/listinfo/users
