Browser support:
Specifies the layout for a set of independent window regions.
This element requires a closing tag.
JavaScript page for this element: frameSet .
Possible members:
border
Specifies the width of the border between frames.
borderColor
Sets the color of the border.
class
Sets the style class or classes that belong to the element.
cols
Sets the widths of the columns within a frameSet element. All frame elements in the same column has the same width as the column.
contentEditable
Sets whether the contents of the object are editable.
frameBorder
Sets whether the frame is surrounded by a 3-D border.
frameSpacing
Sets the space between frames in pixels.
HIDEFOCUS
Specifies whether a dotted rectangle (focus rectangle) is drawn around an object while it has focus.
id
Sets a unique identifier for the object.
lang
Specifies the language of the element.
language
Sets the scripting language for the current element. Use it only for the script element.
name
Sets the name of an element.
rows
Sets the heights of the rows within a frameSet element. All frame elements in the same row have the same height as the row.
style
Sets an inline style associated with an element.
tabIndex
Specifies the tabbing order for keyboard navigation using the TAB key.
title
Specifies a tooltip for an element.
unSelectable
Sets whether the selection process can start in an element's content.
onActivate
Occurs when an element becomes active.
onAfterPrint
Occurs when the browser has built the contents of the current document for printing or for the print preview.
onBeforeActivate
Occurs before an element becomes active.
onBeforeDeActivate
Occurs on the active element before it loses the active state.
onBeforeEditFocus
Occurs before an input:file , input:password , input:text or textarea element or an element in an editable region becomes a UI-activated.
onBeforePrint
Occurs when the browser starts to build the contents of the current document for printing or for the print preview.
onBeforeUnLoad
Occurs before the browser unloads the document and provides a possibility to display a confirmation dialog, where the user can confirm whether he wants to stay or leave the current page.
onBlur
Occurs when an element loses focus.
onControlSelect
Occurs before a control is selected in an editable region.
onDeActivate
Occurs on the active element when it loses the active state.
onFilterChange
Occurs after a filter has changed or finished a transition.
onFocus
Occurs when an element receives focus.
onFocusIn
Occurs before an element receives focus.
onFocusOut
Occurs after an element loses focus.
onLoad
Occurs when an object has been loaded.
onLoseCapture
Occurs when the object loses the mouse capture.
onMouseEnter
Occurs when the user moves the mouse pointer into the area of an element.
onMouseLeave
Occurs when the user moves the mouse pointer out of the element.
onMouseOut
Occurs when the user moves the mouse pointer out of the element.
onMouseOver
Occurs when the user moves the mouse pointer into the element.
onMouseWheel
Occurs when the mouse wheel rolls.
onMove
Occurs when the position of an element's top-left corner is changed.
onMoveEnd
Occurs when the user stops dragging an absolute or relative positioned element in an editable region.
onMoveStart
Occurs when the user starts dragging an absolute or relative positioned element in an editable region.
onPropertyChange
Occurs every time when the value of an element's property is changed.
onReadyStateChange
Occurs when the load state of the data that belongs to an element or a HTML document changes.
onResize
Occurs when the size of an object has changed.
onResizeEnd
Occurs when the user stops resizing an element in an editable region.
onResizeStart
Occurs when the user starts to resize an element in an editable region.
onUnLoad
Occurs before the browser unloads the document.
background
Specifies up to five separate background properties, in a shorthand form.
background-attachment
Specifies whether the background-image should scroll with the contents of the object or not.
background-color
Specifies the color to use for the background of the object.
background-image
Specifies the image to use as the background of the object.
background-position
Sets the position of the background-image within the element.
background-repeat
Specifies how to tile the background-image relative to the upper-left corner of the container object.
behavior
Sets the URL of a behavior file.
border
Sets up to three separate border properties, in a shorthand form.
border-bottom
Sets the color, style and width properties for the element's bottom border, in a shorthand form.
border-bottom-color
Specifies the color of the element's bottom border.
border-bottom-style
Specifies the style of the element's bottom border.
border-bottom-width
Specifies the width of the element's bottom border.
border-color
Specifies the color of the element's border.
border-left
Specifies the color, style and width properties for the element's left border, in a shorthand form.
border-left-color
Specifies the color of the element's left border.
border-left-style
Specifies the style of the element's left border.
border-left-width
Specifies the width of the element's left border.
border-right
Specifies the color, style and width properties for the element's right border, in a shorthand form.
border-right-color
Specifies the color of the element's right border.
border-right-style
Specifies the style of the element's right border.
border-right-width
Specifies the width of the element's right border.
border-style
Specifies the style of the element's border.
border-top
Specifies the color, style and width properties for the element's top border, in a shorthand form.
border-top-color
Specifies the color of the element's top border.
border-top-style
Specifies the style of the element's top border.
border-top-width
Specifies the width of the element's top border.
border-width
Specifies the width of the element's border.
display
Specifies the element's display type.
filter
Specifies the filter or collection of filters applied to the object.
margin
Specifies a shorthand property for setting the top, right, bottom and left margins, in that order.
margin-bottom
Specifies the bottom margin of the object.
margin-left
Specifies the left margin of the object.
margin-right
Specifies the right margin of the object.
margin-top
Specifies the top margin of the object.
visibility
Specifies whether the element is visible.
zoom
Specifies the zoom level of the element's content.
Example HTML code 1:
This example illustrates the use of the frameSet element:
Code
topFrame.htm
mainFrame.htm
< frameset rows = "110,*" cols = "*" border = "10px" >
< frame src = "topFrame.htm" name = "topFrame" scrolling = "No" />
< frame src = "mainFrame.htm" name = "mainFrame" />
</ frameset >
< !DOCTYPE html >
< html >
< head >
< meta charset = "utf-8" />
</ head >
< body >
< h1 > Contents of the top frame </ h1 >
May contain menu items or a logo.
</ body >
</ html >
< !DOCTYPE html >
< html >
< head >
< meta charset = "utf-8" />
< script type = "text/javascript" >
function AddRow (statTable, element, attr, attrValue) {
if (attrValue == null )
attrValue = element. getAttribute (attr);
var row = document . createElement ( "tr" );
var nameCell = document . createElement ( "td" );
var valueCell = document . createElement ( "td" );
nameCell. innerHTML = attr;
valueCell. innerHTML = attrValue;
row. appendChild (nameCell);
row. appendChild (valueCell);
statTable. appendChild (row);
}
function CreateFramesetStat () {
var statTable = document . getElementById ( "frameset_stat" );
var frameSet = window . frameElement . parentNode ;
AddRow (statTable, frameSet, "border" );
AddRow (statTable, frameSet, "borderColor" );
AddRow (statTable, frameSet, "frameBorder" );
AddRow (statTable, frameSet, "frameSpacing" );
AddRow (statTable, frameSet, "cols" );
AddRow (statTable, frameSet, "rows" );
}
function CreateTopFrameStat () {
var statTable = document . getElementById ( "topframe_stat" );
var frame = parent . frames [ 'topFrame' ]. frameElement ;
AddRow (statTable, frame, "noResize" , frame. noResize );
AddRow (statTable, frame, "scrolling" );
}
function CreateMainFrameStat () {
var statTable = document . getElementById ( "mainframe_stat" );
var frame = window . frameElement ;
AddRow (statTable, frame, "noResize" , frame. noResize );
AddRow (statTable, frame, "scrolling" );
}
function CreateStat () {
CreateFramesetStat ();
CreateTopFrameStat ();
CreateMainFrameStat ();
}
</ script >
</ head >
< body onload = "CreateStat ()" >
< table >
< thead >
< tr >
< th > Frameset </ th >
< th > Top frame </ th >
< th > Main frame </ th >
</ tr >
</ thead >
< tbody >
< tr >
< td valign = "top" >
< table border = "1px" cellspacing = "2px" >
< thead >
< tr >
< th > name </ th >
< th > value </ th >
</ tr >
</ thead >
< tbody id = "frameset_stat" >
</ tbody >
</ table >
</ td >
< td valign = "top" >
< table border = "1px" cellspacing = "2px" >
< thead >
< tr >
< th > name </ th >
< th > value </ th >
</ tr >
</ thead >
< tbody id = "topframe_stat" >
</ tbody >
</ table >
</ td >
< td valign = "top" >
< table border = "1px" cellspacing = "2px" >
< thead >
< tr >
< th > name </ th >
< th > value </ th >
</ tr >
</ thead >
< tbody id = "mainframe_stat" >
</ tbody >
</ table >
</ td >
</ tr >
</ tbody >
</ table >
</ body >
</ html >
Did you find this example helpful?
yes
no
Related pages:
External links:
Share:
Digg
Del.icio.us
Reddit
Facebook
Twitter
Diigo
User Contributed Comments