本文介绍了在FF 7.0中停用JavaScript的网域限制的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在开发一个小型的html + JS应用程序,供我自己使用,并且能够访问IFrame的内容或使用Javascript打开窗口,将大大提高我的生产力。

I am developing a small html + JS app for my own use and being ability to access IFrame's content or opened windows' contect with Javascript would greatly improve my productivity.

是否可以禁用Firefox 7.0强加的跨域限制,以便我可以修改iframe中显示的内容。

Is it possible to disable the cross domain restrictions imposed by Firefox 7.0, so that I will be able to modify contents of what is displayed in an iframe?

推荐答案

我想我记得一个类似的问题一会儿在FF。这是值得一试:

I think I remember a similar issue a while ago in FF. This is worth a try:

在您的用户配置文件中有一个文件称为prefs.js。在我的机器上它位于:

There's a file in your user profile called prefs.js. On my machine its located:

C:\Users\simon\AppData\Roaming\Mozilla\Firefox\Profiles\aoagj1zo.default

在文件中有一堆这样的行:

In the file are a bunch of lines like this:

user_pref("accessibility.typeaheadfind.flashBar", 0);
user_pref("app.update.lastUpdateTime.addon-background-update-timer", 1317146699);

尝试添加此行:

user_pref("capability.policy.default.XMLHttpRequest.open", "allAccess");

您应该关闭FF,编辑此文件,然后重新打开FF。

You should probably close FF, edit this file, then reopen FF.

这篇关于在FF 7.0中停用JavaScript的网域限制的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

11-02 12:43