Building HTML Frames: Part I
The
frame concept was first introduced in Netscape Navigator 2.0. In fact, HTML frames are
used to break up one big browser window into several independent frames, each has its own
file. From designing point of view, it's similar to using tables in designing and laying
out data and elements. We begin exploring frames by using examples and explanation.
Example1: A simplest frame set, dividing browser window by
columns
<HTML>
<HEAD>
<TITLE>A Simplest Frame Set</TITLE>
</HEAD>
<FRAMESET COLS = "*,2*">
<FRAME SRC = "menu.html">
<FRAME SRC = "info.html">
</FRAMESET>
</HTML>
Explanation:
The above HTML frame code defines a page with two frames, organized as 2 columns. The
first frame or columns takes up 1/3 of the width of the screen and contains the HTML
document named menu.html. The second frame or column takes up the other 2/3 and
contains the HTML document named info.html.
Example2: A simplest frame set, dividing browser
window by rows
<HTML>
<HEAD>
<TITLE>A Simplest Frame Set</TITLE>
</HEAD>
<FRAMESET ROWS = "*,2*">
<FRAME SRC = "menu.html">
<FRAME SRC = "info.html">
</FRAMESET>
</HTML>
The above HTML frame code defines a page with two frames, organized as 2 rows. The first
frame or row takes up 1/3 of the height of the screen and contains the HTML document named
menu.html. The second frame or row takes up the other 2/3 and contains the HTML
document named info.html.
1.Frame Tags and Attributes