为什么IE限制本地HTML页面的JavaScript文件?

编程入门 行业动态 更新时间:2024-10-21 04:10:05
本文介绍了为什么IE限制本地HTML页面的JavaScript文件?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

为什么IE在我们打开本地html文件时会限制JavaScript文件的运行?消息说:

Why does IE restrict JavaScript files from working when we open a local html file? The message says:

为了保护您的安全,Internet Explorer已限制此网页运行可以访问您计算机的脚本或ActiveX控件。单击此处查看选项

"To help protect your security, Internet explorer has restricted this web page from running scripts or ActiveX controls that could access your computer. Click here for the options"

谁能告诉我如何摆脱这个?

Can anyone tell me how get get rid of this?

推荐答案

查看 msdn.microsoft/en-us /library/ms537628(v=vs.85).aspx

如果您想在Internet区域中运行,请将其添加到您的HTML源代码中:

If you want to run in the Internet zone add this to your HTML source:

<!-- saved from url=(0014)about:internet -->

如果您想在Intranet区域中运行,请将其添加到您的HTML源:

If you want to run in the Intranet zone add this to your HTML source:

<!-- saved from url=(0016)localhost -->

要么停止显示消息并允许JavaScript执行。

Either will stop the message from displaying and allow JavaScript to execute.

这也可以让文件在其他PC上打开,而无需更改Internet Explorer选项。

This will also allow the file to open on other PC's without having to change Internet Explorer options.

更多推荐

为什么IE限制本地HTML页面的JavaScript文件?

本文发布于:2023-10-08 01:36:39,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1471134.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:页面   文件   HTML   JavaScript

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!