当前位置: 首页 > 网络学院 > 网页制作基础教程 > HTML > HTML <iframe>标签
The iframe element creates an inline frame that contains another document.
iframe元素可以让内联的框架中包含另一个文档
NONE
无
代码 | 输出结果 |
---|---|
<iframe src ="/default.asp" width="100%"> </iframe> |
DTD indicates in which DTD the attribute is allowed. S=Strict, T=Transitional, and F=Frameset.
下表中的DTD列指明了被支持的DTD属性。S=Strict(精确的),T=Transitional(传统的),F=Frameset(框架)
属性 | 值 | 描述 | DTD |
---|---|---|---|
align | left right top middle bottom | Specifies how to align the iframe according to the surrounding text 指定iframe应该如何根据周围的文字进行对齐 | TF |
frameborder | 1 0 | Specifies whether or not to display a frame border 指定框架边框是否需要显示 | TF |
height | pixels % | Defines the height of the iframe 指定iframe的高度 | TF |
longdesc | URL | A URL to a long description of the frame contents 为框架内容的描述指定一个URL | TF |
marginheight | pixels | Defines the top and bottom margins of the iframe 定义框架的上下边际 | TF |
marginwidth | pixels | Defines the left and right margins of the iframe 定义iframe的左右边际 | TF |
name | frame_name | Specifies a unique name of the iframe (to use in scripts) 定义iframe唯一的name值(可用于脚本) | TF |
scrolling | yes no auto | Define scroll bars 定义滚动条 | TF |
src | URL | The URL of the document to show in the iframe 定义iframe所要展示的URL | TF |
width | pixels % | Defines the width of the iframe 定义iframe的宽度 | TF |
id, class, title, style |
For a full description, go to Standard Attributes.
查看完整的属性
Inline frame
How to create an inline frame (a frame inside an HTML page).
怎样建立一内联框架(框架内包含一张HTML页面)