14
In JavaScript, let's say we have a main page (main.html) which contains an <iframe> (iframe.html).
Now inside this iframe.html, if we need to refer to something on the main page (main.html), can we not just specify window instead of parent.window.
If the answer is we need to write parent.window, I wanted to understand is there not a single window object reference for all the iframes within a main page...
While I do understand document is specific to individual iframes, but window should be common to all..Isn't it...Please help me in understanding the concept...
Also is there something window.parent as well? If yes, how does it differ from parent.window?