The frameset tag is used to declare multiple
frames. As you can see in our first example, the menu bar side, there
was one frameset. It read:
<frameset cols="15%,85%">
This tells the browser, we are creating column of framed pages, the
first one is to take up 15% of the total browser screen, and
the second is to take up 85% of the total browser screen.
Then, we introduced <frame>, which is what actually loads the
pages. Each frame must have a src, such as src="some_page.htm".
So, because we used two framed areas within the frameset, we need two
frame tags, each of them to load a page.
<frameset cols="15%,85%">
<frame src="menu_bar.htm" name="sidemenu">
<frame src="main.htm" name="mainwindow">
</frameset>
If we would like to add a third column, we would need to add a
third size definition in the cols (so that all would add up to
100%) and another frame tag inside the frameset.
Likewise, we can use a rows definition instead of a columns
definition. If we wanted the menu to be a bottom menu bar, we would do
something like:
<frameset rows="80%,20%">
<frame src="main.htm" name="mainwindow">
<frame src="menu_bar.htm" name="bottommenu">
</frameset>
If you wanted the menu at the top, just switch it around a little
bit:
<frameset rows="20%,80%">
<frame src="menu_bar.htm" name="topmenu">
<frame src="main.htm" name="mainwindow">
</frameset>
|