当我尝试访问的iframe,我得到这个错误,我不知道我做错了。有人可以帮我解决这个问题吗?访问的IFrame
var ifrm = document.getElementById('iframe'),
ifrm = (ifrm.contentWindow) ? ifrm.contentWindow :
(ifrm.contentDocument.document)
? ifrm.contentDocument.document :
ifrm.contentDocument;
ifrm.open();
ifrm.write("Hello World!");
ifrm.close();
这是我收到的错误:
遗漏的类型错误:未定义
遗漏的类型错误的无法读取属性 '文件':无法读取的不确定
财产 '的readyState'
***不能读取属性“文件”的不确定***是相当清楚的 – xandercoded
'iframe.contentWindow'是不是跨浏览器? –
附注:对嵌套的三元运算符说“不”。 – FishBasketGordo