How can I remove default zoom in/out [+/-] buttons from openlayers to keep the naviga

المشرف العام

Administrator
طاقم الإدارة
I want to remove the default zoom +/- buttons from openlayers.

Here is my code

when I added, controls: [ new OpenLayers.Control.Navigation(), new OpenLayers.Control.ArgParser(), new OpenLayers.Control.Attribution() ]to the map = new OpenLayers.Map, to remove default zoom +/- buttons, the map is not loading.Please see the image also.

Both the navigation buttons exist. :(

I want to remove the small- 2 button- one.I changed the code like this:

map = new OpenLayers.Map('map', {zoomDuration: 1,projection: 'EPSG:3857' controls: [] });and added

map.addControl(new OpenLayers.Control.PanZoomBar()); map.addControl(new OpenLayers.Control.KeyboardDefaults());But, the map is not loading. Do not know any syntax error..



أكثر...
 
أعلى