<frameset>

line.gif

Specifies a set of frames.

Syntax

<frameset cols=n rows=n frameborder=n framespacing=n>
...
...
</frameset>

Attributes

cols A comma separated list defining the number and width of columns containing the frames. Each entry is specified as a percentage of the browser window (e.g. 20%). Additionally, an entry can use the character '*' to allow the browser to calculate the width (see below).
rows A comma separated list defining the number and height of rows containing the frames. Each entry is specified as a percentage of the browser window (e.g. 20%). Additionally, an entry can use the character '*' to allow the browser to calculate the height (see below).
frameborder A value of zero indicates no border; whereas, a value of 1 (the default) indicates that a border should be drawn around the frames contained in the frame set.
framespacing The spacing (in pixels) to be applied between frames in the frame set.


Notes

Example

The following example demonstrates how to define a frame set.

<html>
<head>
<title>Example Using Frames - HTML Reference</title>

<frameset rows="50%,*" cols="33%,*,*">
 <frame src=frameA.htm>
 <frame src=frameB.htm>
 <frame src=frameC.htm>
 <frame src=frameD.htm>
 <frame src=frameE.htm>
 <frame src=frameF.htm>
</frameset>
</head>
</html>

The example shown above is stored in the document framesmp.htm. Take this link to run the sample. Hit the back button to return to this panel. The source for each of the frames in the frame set is found in a separate HTML document. One of those documents is shown below (frameA.htm).

<html>
<head>
<title>frameA</title>
</head>
<body>
<p>FrameA
</body>
</html>

Note the effect of the asterisk in the cols attribute above. The first column is explicitly specified as 33% (approximately 1/3 of the screen); whereas, the second and third columns are specified using the asterisk. The asterisk has the effect of distributing the remaining space evenly between the columns defined in this manner.