HTML Frame Borders: Legacy frameborder and Modern CSS

Legacy topic: <frame> and its frameborder attribute are obsolete. The examples below are for maintaining old code.

The historical frameborder attribute controlled whether a border appeared around a frame in a frameset.

Historical frameborder syntax Top ↑

<frameset cols="50%,50%">
  <frame src="frame1src.html" frameborder="0">
  <frame src="frame2src.html" frameborder="0">
</frameset>

Modern iframe border control Top ↑

For a current <iframe>, control the visible border with CSS rather than old frame presentation attributes.

<iframe class="embedded-page" src="example.html" title="Example page"></iframe>

.embedded-page {
  border: 0;
}

Frequently Asked Questions Top ↑

Should I use frameborder="0" today?
No for new HTML. Use CSS on an iframe when a border needs to be removed.

Does CSS border work on iframe?
Yes. An iframe is a normal element whose outer border can be styled with CSS.

Frames overview Modern iframe





plus2net.com










✖
We use cookies to improve your browsing experience. . Learn more
HTML MySQL PHP JavaScript ASP Photoshop Articles Contact us
© 2000-2026 plus2net.com All rights reserved worldwide Privacy Policy Disclaimer