HTML - Frame tag

Example (Only Rows):
<HTML>
<HEAD>
<TITLE>Frames Example</title>
</HEAD>
<FRAMESET rows="15%, 85%">
<FRAME src="try.html">
<FRAME src="hi.html">
</FRAMESET>
</HTML>
 
Example (Only Columns):
<HTML>
<HEAD>
<TITLE>Frames Example</title>
</HEAD>
<FRAMESET cols="200, *">
<FRAME src="try.html">
<FRAME src="hi.html">
</FRAMESET>
</HTML>
 
Example (Rows & Columns):
<HTML>
<HEAD>
<TITLE>Frames Example</title>
</HEAD>
<FRAMESET rows="33%,33%,*" cols="20%,80%">
<FRAME src="try.html">
< FRAME src="try.html">
< FRAME src="try.html">
< FRAME src="try.html">
< FRAME src="try.html">
< FRAME src="try.html">
</FRAMESET>
</HTML>
 
Example (Rows & Columns):
<HTML>
<HEAD>
<TITLE>This is the title of my site</TITLE>
</HEAD>
<FRAMESET rows=”200, *”>
<FRAME name=”banner” src=”hi.html” noresize  scrolling=”no”>
<FRAMESET cols=”25%, 75%”>
<FRAME name=”navigate” src=”orderedlist.html”>
<FRAME name=”main” src=” unorderedlist.html”>
</FRAMESET>
</FRAMESET>
<NOFRAMES>
This browser dose not support frames.
</NOFRAMES>
</HTML>
 
Frames are a way of dividing your browser window so it can hold more than one logical page. Frames allow the user to load different URLs in different part of browser. Frames have never been an official part of the HTML specification. The World Wide Web Consortium (W3C) has finally embraced frames or at least recognized frames by adding the <FRAME>, <FRAMESET>, <NOFRAMES>, and <IFRAME> tags to the HTML 4.0 specification. Framesets are what you use to define the presence of frames on your page. The IFRAME element is truly new to HTML and is a fabulous way to introduce an element to your page that stays consistent across pages. Unfortunately, the IFRAME element is not supported in both the major browsers, but the IFRAME element may well replace the FRAME element, once it is well supported.
 
Here are a few rules regarding frameset documents that you should keep in mind:
 - The <FRAMESET> tag follows immediately after the closing </HEAD> tag.
 - If any <BODY> elements appear before the <FRAMESET> tag, the <FRAMESET> elements are ignored.
 - Between the outermost <FRAMESET> tags, you can only nest other <FRAMESET> tags or <FRAME> tags - no other HTML is allowed.
 
How does the browser know it needs to load more than one URL and where to put each one? You create a master frame document. Instead of a <BODY> tag, you create a <FRAMESET> tag or, nested <FRAMESET> tags. The master frame document is a standard HTML document, but there is no <BODY> tag. Instead, there is a <HEAD>, and a <FRAMESET> tag.
 
Attributes of <FRAMESET> tag are:
 
bordercolor: This attribute sets border color of frame.
cols: This attribute is used to indicate the width of the columns in order from left to right; the default is 100%, meaning one column; you can specify the widths in pixels, a percentage of the browser window, or relative width.
rows: This attribute is used to indicate the widths of the rows in order from top to bottom; the default is 100%, meaning one row; you can specify the widths in pixels, a percentage of the browser window, or relative width.
frameborder: This attribute is specifies whether or not to display a border for the frame.
title: The Title attribute is used to provide advisory information.
 
Attributes of <FRAME> tag are:
 
src: This attribute is used to specify what should initially be loaded into this frame.
name: This attribute specifies how you want to refer to the frame. This is called the target name of the frame.
frameborder: This attribute tells browser to draw a border around this frame (1, the default value), or not to draw a border (0); if the adjoining frame has a frameborder, it will appear between the unbordered frame and the bordered frame.
marginwidth: This attribute specifies the width of margin in pixels (margin between frame contents and borders on sides).
marginheight: This attribute specifies height of margin in pixels (margin between frame contents and borders on top and bottom).
noresize: This is a Boolean attribute that tells the browser that this frame is not resizable by the visitor.
scrolling: There are three values for this attribute: yes, no, and auto. Choose no if you know the contents of the frame will always fit into the frame. Choose yes if you want there always to be a scroll bar on the side of this frame. Choose auto if you want the browser only to display a scroll bar if the content doesn’t fit into the frame.
 
<NOFRAMES> and </NOFRRAMES> contains the page you want users to get if their browsers do not support frames, or if their browsers support frames but are configured not to display frames. It could be as simple as a message telling them to upgrade their browsers or enable frames to see your site properly.