jQuery gets the window object of iframe
var win = $('#ifr')[0].contentWindow;
JS native method to get window object of iframe
document.getElementById("ifr").contentWindow;
It can be seen that $('#ifr')[0].contentWindow and document.getElementById("ifr") are equivalent
Looking at the following situation
var ifr1 = document.getElementById("ifr");
var ifr2 = window.frames[0];
ifr2.frameElement is equivalent to ifr1;
The above article on JS to obtain window objects in iframe is all the content I have shared with you. I hope you can give you a reference and I hope you can support Wulin.com more.