HTML Frames

In this tutorial we ll see about frames on your  web page. but nowdays as per  web standard we not using frames.. anyway for basic we ll learn here something about frames.

Frames is nothing but displaying multiple frames in one web  page. Its like we accessing other pages from one page with <a> anchor tag.

With frames, you can display more than one HTML document in the same browser window. Each HTML document is called a frame, and each frame is independent of the others.

The disadvantages of using frames are:

  • The web developer must keep track of more HTML documents
  • It is difficult to print the entire page

The HTML frameset Element

The frameset element holds two or more frame elements. Each frame element holds a separate document.

The frameset element states only HOW MANY columns or rows there will be in the frameset.

The HTML frame Element

The <frame> tag defines one particular window (frame) within a frameset.

In the example below we have a frameset with two columns.

The first column is set to 25% of the width of the browser window. The second column is set to 75% of the width of the browser window. The document “frame_a.htm” is put into the first column, and the document “frame_b.htm” is put into the second column:

<frameset cols=”25%,75%”>
<frame src=”frame_a.htm” />
<frame src=”frame_b.htm” />
</frameset>

Note: The frameset column size can also be set in pixels (cols=”200,500″), and one of the columns can be set to use the remaining space, with an asterisk (cols=”25%,*”).

About Jagadesh Boopathi

I am tech savy spending more time on technology, learning about web, making time to find new stuff always. Also I am Entrepreneur, Blogger and an Engineer. Open Source - Matters.

View all posts by Jagadesh Boopathi →

Leave a Reply

Your email address will not be published. Required fields are marked *