在Android 4.4及更高版本的设备中会出现以下问题。iframe的安全错误
这是我们的iframe的样子:
<iframe frameborder=0 id="myIFRAME"></iframe>
以下是我们编程变得IFRAME方式:
if(document.getElementById("myIFRAME")){
me.setMyIFRAME(document.getElementById("myIFRAME").contentWindow);
}
这导致相关协议不匹配安全错误:
"Uncaught SecurityError: Blocked a frame with origin " https://www.google.com " from accessing a frame with origin "file://". The frame requesting access has a protocol of "https", the frame being accessed has a protocol of "file". Protocols must match.
我们正在使用煎茶触摸与科尔多瓦发展我们的项目。
我必须使用这个 – Vishnu