javascript - 我们如何找到任何 iframe 中的页面的样式表?
问题描述
我们如何找到任何 iframe 中的页面的样式表。
<iframe id="#iframe" src="view_page.php"
style="transition: none 0s ease 0s;" width="750" height="899"></iframe>
console.log(document.styleSheets);
如果页面在没有 iframe 的浏览器中加载,则上述内容将起作用。document.styleSheets 将给出一个样式表数组,包含在文件中。但是,当页面在 iframe 内时,它不起作用。
解决方案
推荐阅读
- javascript - 复选框选中和取消选中任务
- dspace - Dspace 元数据标题自定义
- firebase - Square 和 Firebase 之间有集成吗?
- ios - 如何防止得到
从 NSUserDefaults 检索一个对象 - c# - Net Core Web API 2.2 保护敏感数据
- sql - SQL + Powershell:当WHERE匹配时选择语句对匹配的行中的列执行更新
- c# - 我的请求在 HTTPClient 和 RestSharp 中不起作用,但在 Postman 中却很好
- django - 同一个表但不同列的多个外键获取models.object
- c++ - C++ 编译器为什么/如何理解类实例的这种初始化?
- sql-server - 使用 Row_number() 和 Partition,然后排序 desc,并在 DB2 中选择顶部结果