禁用html页面大小调整 [英] Disable the html page resizing

查看:65
本文介绍了禁用html页面大小调整的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想禁止用户调整html网页的大小.怎么做我想禁用调整大小按钮,并通过拖动手动调整大小.请帮助

Hi I want to disable the resizing the html web page by the user. How to do that I want to disable the resize button and manual resizing by dragging. pls help

推荐答案

您不能,谢谢上帝.

当您打开一个新的弹出窗口时,您可以使用功能 resizable :

When you open a new popup you can request it be unresizable using the feature resizable:

window.open('something.html', '_blank', 'resizable=no');

但是,现代的浏览器可能会忽略您的请求,因为它被视为极度不利于用户的行为.

however modern browsers may ignore your request as it is considered egregiously user-hostile.

使用液体布局可以使页面灵活地响应窗口大小的变化,而不是尝试将其设置为具体的.网络本质上是可变大小的媒介,无论如何,移动浏览器用户都无法获得屏幕大小的输入.

Use liquid layout to make your page respond flexibly to changes in window size, rather than attempting to set it in concrete. The web is inherently a variable-size medium, and mobile browser users get no input in how large their screen is anyway.

这篇关于禁用html页面大小调整的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆