HTML <iframe> frameborderAttribute

HTML iframe 标签参考手册HTML <iframe> Tag

Examples

An <iframe> without a border:

<iframe src="http://www.w3cschool.cc/" width="200" height="200" frameborder="0">
</iframe>

Try it Yourself »

Browser Support

Internet ExplorerFirefoxOperaGoogle ChromeSafari

All major browsers support the frameborder attribute.


Definition and Usage

HTML5 does not support the <iframe> frameborder attribute. Please use CSS instead.

The frameborder attribute specifies whether or not to display a border around the <iframe>.

Tip:For practical reasons, it is best not to set this attribute; use CSS to applyborder。

CSS Example: iframe border


Syntax

<iframe frameborder="1|0">

Attribute Values

Value Description
1 Default. Enables the border.
0 Disables the border.


HTML iframe 标签参考手册HTML <iframe> Tag Other Extensions