ExternalInterface 是 ActionScript 中的一个类,它允许 ActionScript 代码与 JavaScript 代码进行交互。以下是关于 ExternalInterface 的一些常见问题:
\\ 或者使用 escapeMessage 函数来转义字符串。Security.allowDomain 和 Security.allowInsecureDomain。Security.allowDomain("*") 和 Security.allowInsecureDomain("*") 来允许跨域通信,或者为请求加上时间戳以示区别。\\ 或者 escapeMessage 函数来转义包含反斜杠的字符串。Security.allowDomain 和 Security.allowInsecureDomain 来允许跨域通信,或者为请求加上时间戳以示区别。请注意,由于 ExternalInterface 是 Adobe Flash 的一部分,而 Flash 已经被 Adobe 弃用,因此在实际开发中应避免使用 ExternalInterface,并寻找替代的技术方案。