如何删除 Opera Mobile 中的缩放图标
我正在为 Opera Mobile 设计一个网页。它的左上角有一个小缩放图标。当我访问 www.opera.com 时,该图标变得不可见并且缩放级别变得固定。对于任何其他网页,它都会出现,我可以放大和缩小页面。我也希望我的页面具有相同的固定缩放行为。这可能是一些CSS属性。您知道我应该在哪些对象上设置哪些属性吗?或者您认为还有另一种方法可以实现这一目标吗?
谢谢。
I am designing a web page for Opera Mobile. It has a little zoom icon on the left right corner. When I visit www.opera.com, this icon becomes invisible and zoom level becomes fixed. For any other web page it appears and I can zoom in and out of the page. I want the same fixed zoom behavior in my page too. It is probably some css property. Do you know what properties should I set and on which objects? Or do you think there would be another way to accomplish this.
Thank you.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
看起来他们正在使用“viewport”元标记来指定页面的宽度。这可能设置为小于移动 Opera 的可用屏幕宽度,因此不需要缩放按钮。
以下是 Opera.com 移动版本上使用的标签:
为了防止页面缩放,我会将标签设置如下:
尽管从 UI 角度来看,阻止用户缩放并不是我的首选。
opera 开发者网站描述了对此的支持标签:
It looks like they are using the "viewport" meta tag to specify the width of the page. This probably is set to smaller than mobile Opera's available scren width, so the Zoom button is not needed.
Here is the tag as it is used on the mobile version of Opera.com:
To keep your page from scaling, I would set the tag to be as follows:
Although keeping the user from scaling would not be my first choice UI-wise.
The opera developer site describes the support of this tag: