Author Options:

How do I use an Iframe as the source for another Iframe? Answered

In html the iframe tag asks for a source, usually a web page or web document.
I think it might be possible for an iframe to reference another iframe.
Let me know if I am wrong or if you have any suggestions on how to do this. 




Best Answer 8 years ago

Here is the primary documentation for the HTML markup language. The iframe tag is part of HTML5.

It looks like you probably can, although it is not obvious what the consequences will be. First, the src (or srcdoc) attribute takes any non-empty URL argument, so you can use a targeted URL (i.e., <path>#<name>). In the iframe you want to use as the source, you would give thatiframe the name attribute with a value of the name you want to use as a reference.

This suggestion is only based on reading the appropriate standard (which you should already have access to and be reading!), not any sort of experimental verification with any particular browser.