HTML | PHP | Forum

HTML <frame> tag



Definition and Usage

The FRAME element defines a frame--a rectangular subspace within a Frameset document. Each FRAME must be contained within a FRAMESET that defines the dimensions of the frame.

Optional Attributes

Attribute Value Description
frameborder 0
Specifies whether or not to display border around the frame.
longdesc URL An URL to a long description of the frame contents. Use it for browsers that do not support frames
marginheight pixels Defines the top and bottom margins in the frame
marginwidth pixels Defines the left and right margins in the frame
name frame_name Defines a unique name for the frame 
noresize noresize To allow or not the user to resize the frame
scrolling yes
Determines scrollbar action
src URL Defines the URL of the file to be shown in the frame

Standard Attributes

Only allowed in XHTML 1.0 Frameset DTD!!

id, class, title, style

For a full description, go to Standard Attributes.


Source Output
<a href="testframe.htm" target="_blank">View this page in a new window</a>

The source code in "testframe.htm":
<frameset cols = "50%, 50%">
  <frame src ="frame1.htm" />
  <frame src ="frame2.htm" />

View this page in a new window


Learn HTML
HTML Tutorial

HTML Reference
HTML by function
HTML by Alphabet

HTML events
HTML attributes
HTML color names

<h1> to <h6>


Copyright 2005-8 Sunilcare.  All Rights Reserved.
Comments or suggestions? Contact us.About us