Приглашаем посетить
Спорт (www.sport-data.ru)

Summary

Previous Page
Table of Contents
Next Page

Summary

In this hour you learned how to display more than one page at a time by splitting the web browser window into frames. You learned to use a frameset document to define the size and arrangement of the frames, as well as which web page or image will be loaded into each frame. You saw how to create links that change the contents of any frame you choose, while leaving the other frames unchanged. You also discovered several optional settings that control the appearance of resizable borders and scrollbars in frames. Finally, you saw how to nest framesets to create complex frame layouts.

Table 16.1 summarizes the tags and attributes covered in this hour.

Table 16.1. HTML Tags and Attributes Covered in Hour 16

Tag/Attribute

Function

<frameset></frameset>

Divides the main window into a set of frames that can each display a separate document.


Attributes

rows="numrows"

Splits the window or frameset vertically into a number of rows specified by a number (such as 7), a percentage of the total window width (such as 25%), or an asterisk (*) indicating that a frame should take up all the remaining space or divide the space evenly between frames (if multiple * frames are specified).

cols="numcols"

Works similar to rows, except that the window or frameset is split horizontally into columns.

frameborder="yes/no"

Specifies whether to display a border for a frame. Options are 1 (yes) and 0 (no).

<frame />

Defines a single frame within a <frameset>.


Attributes

src="url"

The URL of the document to be displayed in this frame.

id="name"

A name to be used for targeting this frame with the target attribute in <a href> links; compliant with XHTML but not quite supported for frames in current web browsers.

name="name"

A name to be used for targeting this frame with the target attribute in <a href> links; will eventually be replaced by id but for the time being is still useful because it works in current web browsers.

<marginwidth>

The amount of space (in pixels) to leave to the left and right side of a document within a frame.

<marginheight>

The amount of space (in pixels) to leave above and below a document within a frame.

scrolling="yes/no/auto"

Determines whether a frame has scrollbars. Possible values are yes, no, and auto.

noresize="noresize"

Prevents the user from resizing this frame (and possibly adjacent frames) with the mouse.

<noframes></noframes>

Provides an alternative document body in <frameset> documents for browsers that do not support frames (usually encloses <body></body>).

<iframe></iframe>

Creates an inline frame.

(<iframe> accepts all the same attributes as does <frame />.)



Previous Page
Table of Contents
Next Page