iframe Element

An iframe element in the object model of an HTML document provides content to be displayed in an internal frame. When creating a document with HTML code in serialized form, use an <iframe/> tag to create an iframe element.

HTMLIFrameElement interface
Superinterface:
HTMLElement
HTML Tag Reference:
<iframe> tag
DOM Properties
get or setDocument
element.contentDocument
element.contentDocument = value
get or setWindowProxy
element.contentWindow
element.contentWindow = value
get or setDOMString
element.height
element.height = value
get or setDOMString
element.name
element.name = value
get onlyDOMSettableTokenList
element.sandbox
element.sandbox = value
get or setboolean
element.seamless
element.seamless = value
get or setDOMString
element.src
element.src = value
get or setDOMString
element.srcdoc
element.srcdoc = value
get or setDOMString
element.width
element.width = value
DOM Properties inherited from HTMLElement
get or setDOMString
iframe.className
The class name(s) from the class attribute.
get or setDOMString
iframe.dir
The direction of text flow.
get or setDOMString
iframe.id
The element's unique ID.
get or setDOMString
iframe.lang
The language of text inside the element.
get or setDOMString
iframe.title
The iframe's title.
DOM Events
Event TypeProperty
abortFunctiononabort
canplayFunctiononcanplay
canplaythroughFunctiononcanplaythrough
changeFunctiononchange
clickFunctiononclick
contextmenuFunctiononcontextmenu
cuechangeFunctiononcuechange
dblclickFunctionondblclick
dragFunctionondrag
dragendFunctionondragend
dragenterFunctionondragenter
dragleaveFunctionondragleave
dragoverFunctionondragover
dragstartFunctionondragstart
dropFunctionondrop
durationchangeFunctionondurationchange
emptiedFunctiononemptied
endedFunctiononended
formchangeFunctiononformchange
forminputFunctiononforminput
inputFunctiononinput
invalidFunctiononinvalid
keydownFunctiononkeydown
keypressFunctiononkeypress
keyupFunctiononkeyup
loadeddataFunctiononloadeddata
loadedmetadataFunctiononloadedmetadata
loadstartFunctiononloadstart
mousedownFunctiononmousedown
mousemoveFunctiononmousemove
mouseoutFunctiononmouseout
mouseoverFunctiononmouseover
mouseupFunctiononmouseup
mousewheelFunctiononmousewheel
pauseFunctiononpause
playFunctiononplay
playingFunctiononplaying
progressFunctiononprogress
ratechangeFunctiononratechange
readystatechangeFunctiononreadystatechange
resetFunctiononreset
seekedFunctiononseeked
seekingFunctiononseeking
selectFunctiononselect
showFunctiononshow
stalledFunctiononstalled
submitFunctiononsubmit
suspendFunctiononsuspend
timeupdateFunctionontimeupdate
volumechangeFunctiononvolumechange
waitingFunctiononwaiting