Modify the nested style in ifream

Modify the nested style in ifream

The style of ifream can only be modified by js

let codeTips = document.getElementById("iframe的id").contentWindow.document.getElementById("找到ifream里面的id")
codeTips.style.zIndex = '5'
//将样式的z-index改为5 注意是要驼峰的写法

Through the above search, the nodes in ifream can be obtained for modification.
document.getElementById("iframe id") can be searched with ref.

Guess you like

Origin blog.csdn.net/qq_39367226/article/details/107532398