I'm having trouble getting the parent ID of a document that "iframe1" is here as you see Javascript should be in the "" section. Are you giving me some ideas?
Yes, I know I can include JavaScript at the top, but I believe I can slip for some purpose because I am including it in many other codes.
& lt; Html & gt; & Lt; Iframe id = "iframe1" & gt; & Lt; Html & gt; & Lt; Top & gt; & Lt; JavaScript & gt; & Lt; / Head & gt; & Lt; Body & gt; & Lt; / Body & gt; & Lt; / Html & gt; & Lt; / Iframe & gt; & Lt; / Html & gt;
The frame is on the same domain as the parent, to get you A reference to iframe that you can use, if it is not on the same domain, the security restrictions will prevent you from accessing the parent document.
var frameId = window.frameElement.id;
Comments
Post a Comment