2

在 HTML 容器中运行使用 localConnection 的 flash 组件时,我在弹出框中收到以下错误(flash player 是调试版本):

错误 #2044:未处理的 SecurityErrorEvent:。text=Error #2047:安全沙箱违规:LocalConnection.send:127.0.0.1 无法访问

4

4 回答 4

3

将页面的 URL 从http://127.0.0.1/更改为http://localhost/解决了这个问题。

于 2009-01-25T16:38:08.220 回答
2

// 在接收文件的实例化之后添加这一行

receiveSwf_lc.allowDomain("localhost");

// 或者你喜欢的任何域名,使用 * 作为通配符来允许任何域名

于 2009-02-06T14:24:27.867 回答
0

您也可能想要添加一个 crossdomain.xml 文件,但这里有一个不错的解释:http ://scottrockers.com/blog/resources/flash-information/workaround-solution-to-flash-error-2044-unhandled-securityerror -and-error-2048-security-sandbox-violation

于 2011-04-27T21:32:20.300 回答
0

您也可以添加主机文件条目并将其指向 127.0.0.1。

于 2013-02-20T20:35:02.020 回答