Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/javascript/392.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Javascript 禁用IE11中的浏览器缩放_Javascript_Css_Internet Explorer_Zooming - Fatal编程技术网

Javascript 禁用IE11中的浏览器缩放

Javascript 禁用IE11中的浏览器缩放,javascript,css,internet-explorer,zooming,Javascript,Css,Internet Explorer,Zooming,我想禁用IE11中的缩放功能。 我找到了这条线 <script>document.firstElementChild.style.zoom = "reset";</script> document.firstElementChild.style.zoom=“重置”; 做我真正想做的事,但只在chrome中起作用。是否有IE11的替代品。使用 <meta name="viewport" content="width=device-width, initial-sc

我想禁用IE11中的缩放功能。 我找到了这条线

<script>document.firstElementChild.style.zoom = "reset";</script>
document.firstElementChild.style.zoom=“重置”;
做我真正想做的事,但只在chrome中起作用。是否有IE11的替代品。

使用

<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">


在文档的
部分,以防止在移动设备上缩放网站。这里重要的是
user scalable=no
,这就是诀窍。

有吗?可能重复:谢谢你们两位;但我并不是说在移动设备上禁用“打孔后缩放”和“选择”;我的意思是在使用工具栏中的“放大”“缩小”时禁用缩放。谢谢,但这在我的情况下不起作用;我想要的行为是当从浏览器工具栏缩放时,我想要页面不改变,我的意思是什么也不发生。有没有办法在页面加载时设置注册表以禁用缩放,然后在会话结束时启用缩放?看看这个。我认为这是不可能的。虽然它确实说这只在IE中可能:D@Amirado我在一些地方阅读过,除非你能以某种方式访问注册表或系统设置,否则你无法通过页面上的任何脚本控制应用程序(IE)的功能。