English 中文(简体)
如何利用开放式图书馆在超文本档案中消除动物特征?
原标题:How to remove zoom feature in HTML file using openlayers library?

I want to remove the zoom-in and zoom-out buttons on my application. When I run it on the browser and click inspect I can see this line "<button class="ol-zoom-in" type="button" title="Zoom in">+</button>" but in my code editor, I am not able to find it.I m using openlayer 6.5.0 Inspect screenshot

问题回答
const map = new Map({
    controls : defaults({
        attribution : false,
        zoom : false,
    }),
});

在座标上可见的洞ton动物在开放式世界被称作控制,可以在绘制地图标的时加以配置。

具体来说,你可以通过将不履约的动物群控制区(动物群和动物群)排除在你地图组合的控制清单之外,去除。

见下文例子。

const map = new Map({
  target:  mapDOMElement , 
  view: yourConfiguredView,
  layers: [...yourLayers],
  controls: [], // An empty array to remove all default controls
});




相关问题
CSS working only in Firefox

I am trying to create a search text-field like on the Apple website. The HTML looks like this: <div class="frm-search"> <div> <input class="btn" type="image" src="http://www....

image changed but appears the same in browser

I m writing a php script to crop an image. The script overwrites the old image with the new one, but when I reload the page (which is supposed to pickup the new image) I still see the old one. ...

Firefox background image horizontal centering oddity

I am building some basic HTML code for a CMS. One of the page-related options in the CMS is "background image" and "stretch page width / height to background image width / height." so that with large ...

Separator line in ASP.NET

I d like to add a simple separator line in an aspx web form. Does anyone know how? It sounds easy enough, but still I can t manage to find how to do it.. 10x!

热门标签