Webmaster

HTML : Frames
Contents ]
Jérôme Versavel

Nested Frames

A frame can easily be divided into other frames by nesting another <FRAMESET> definition.

<FRAMESET COLS="100,*">
<FRAME NAME="left" SRC="menu.html">
<FRAMESET ROWS="20%,80%">
<FRAME NAME="top" SRC="banner.html">
<FRAME NAME="main" SRC="main.html">
</FRAMESET>
<NOFRAMES>
Your browser does not support frames.
<A HREF="noframes.html">Page without frames</A>
</NOFRAMES>
</FRAMESET>

We have just created three frames:

  • A first 100-pixel-wide vertical frame on the lefthand side of the window which contains the file menu.html.

  • Another one top aligned, for the file banner.html, which takes up 20% of the window height.

  • And a third one for the file main.html, which is allotted the remaining window space (* in width, 80% in height).



  • Figure 2: Rendering of our three frames, two of which are nested.

Compatibility. In the previous example, we introduced the <NOFRAMES> tag. It contains all the code for situations where frames are not supported.



  1   2   3   4   5   6   7