iframe 通信之坑

iframe,如果是不同域名的iframe资源,直接调用:window.parent.flag = true, 会报跨域的错误。只能通过poseMessage方式来通信。

posted @ 2020-08-14 13:30  田木夕  阅读(171)  评论(0编辑  收藏  举报