<noframes>: The Frame Fallback element - HTML: HyperText Markup Language 编辑

Obsolete

This feature is obsolete. Although it may still work in some browsers, its use is discouraged since it could be removed at any time. Try to avoid using it.

The obsolete HTML No Frames or frame fallback element, <noframes>, provides content to be presented in browsers that don't support (or have disabled support for) the <frame> element. Although most commonly-used browsers support frames, there are exceptions, including certain special-use browsers including some mobile browsers, as well as text-mode browsers.

A <noframes> element can contain any HTML elements that are allowed within the body of an HTML document, with the exception of the <frameset> and <frame> elements, since using frames when they aren't supported doesn't make sense.

<noframes> can be used to present a message explaining that the user's browser doesn't support frames, but ideally should be used to present an alternate form of the site that doesn't use frames but still offers the same or similar functionality.

In HTML 5 and later, <noframes> is obsolete and shouldn't be used, since the <frame> and <frameset> elements are also obsolete. When frames are needed at all, they should be presented using the <iframe> element.

Attributes

Like all other HTML elements, this element supports the global attributes. It has no other attributes available.

Example

In this example, we see a frameset with two frames. In addition, <noframes> is used to present an explanatory message if the user agent doesn't support frames.

<frameset cols="50%,50%">
  <frame src="/wiki/en/HTML/Element/frameset" />
  <frame src="/wiki/en/HTML/Element/frame" />
  <noframes><p>It seems your browser does not support frames or is
  configured to not allow them.</p></noframes>
</frameset>

Specifications

SpecificationStatusComment
HTML5
The definition of 'noframes' in that specification.
Recommendation 
HTML 4.01 Specification
The definition of '<noframes>' in that specification.
Recommendation 

Browser compatibility

BCD tables only load in the browser

See also

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。
列表为空,暂无数据

词条统计

浏览:48 次

字数:4502

最后编辑:7年前

编辑次数:0 次

    我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
    原文