Home | | Internet Programming | HTML Frames

Chapter: Web or internet Programming : Scripting Elements

HTML Frames

With frames, we 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.

Frames

 

With frames, we 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.

 

Frameset Tag

•       The <frameset> tag defines how to divide the window into frames

•       Each frameset defines a set of rows or columns

•       The values of the rows/columns indicate the amount of screen area each row/column will occupy

 

Frame Tag

•       The <frame> tag defines what HTML document to put into each frame

 

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 HTML document "frame_a.htm" is put into the first column, and the HTML 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 value can also be set in pixels (cols="200,500"), and one of the columns can be set to use the remaining space (cols="25%,*").

 

•       You cannot use the <body></body> tags together with the <frameset></frameset> tags!

 

The disadvantages of using frames are:

•       The web developer must keep track of more HTML documents

•       It is difficult to print the entire page

 

Study Material, Lecturing Notes, Assignment, Reference, Wiki description explanation, brief detail
Web or internet Programming : Scripting Elements : HTML Frames |


Privacy Policy, Terms and Conditions, DMCA Policy and Compliant

Copyright © 2018-2027 BrainKart.com; All Rights Reserved. Developed by Therithal info, Chennai.