摘要: module dom {[Supplemental, NoInterfaceObject]interface NodeSelector {Element querySelector(in DOMString selectors);NodeList querySelectorAll(in DOMString selectors);};Document implements NodeSelector;DocumentFragment implements NodeSelector;Element implements NodeSelector;};[html]从接口定义可以看到Document、D 阅读全文
posted @ 2013-10-25 16:51 stephenykk 阅读(516) 评论(0) 推荐(0) 编辑
摘要: 以前如果要使iframe里面的脚本能访问parent的内容,但iframe和parent的二级域名相同,那一般都会在两者都写上document.domain="xxx.com" 以放宽访问权限。今天发现,如果iframe和parent在同一个三级域名下,比如都是aa.bb.com,那设了document.domain反而会造成访问拒绝。查了下MSDN,有如下解释:RemarksThe property initially returns the host name of the server from which the page is served. The proper 阅读全文
posted @ 2013-10-25 15:48 stephenykk 阅读(1107) 评论(0) 推荐(0) 编辑