HTML frame Tag
The information on this page is based on HTML version 4.01 (which is the current version of HTML). The next version, HTML 5, is currently being written. Here's a list of HTML 5 tags.
The HTML frame tag is used to specify each frame within a frameset. For example, you can have a left frame for navigation and a right frame for the main content. For each frame, you specify the frame with the frame tag.
Also see:
Frames are not supported in HTML 5 due to the usability issues that they have caused. Despite this, HTML 5 still allows the <iframe> tag.
| Example |
<html>
<head>
<title>Frameset page<title>
</head>
<frameset cols = "25%, *">
<noframes>
<body>Your browser doesn't support frames.
Therefore, this is the noframe version of the site.</body>
</noframes>
<frame src ="/html/tags/frame_example_left.html" />
<frame src ="/html/tags/frame_example_right.html" />
</frameset>
</html>
View the result
|
| Attributes: |
| Attributes specific to this tag: |
| Attribute | Description |
| name | Assigns a name to a frame. This is useful for loading contents into one frame from another. |
| longdesc | A long description - this can elaborate on a shorter description specified with the title attribute. |
| src | Location of the frame contents (for example, the HTML page to be loaded into the frame). |
| noresize | Specifies whether the frame is resizable or not (i.e. whether the user can resize the frame or not). |
| scrolling | Whether the frame should be scrollable or not (i.e. should scrollbars appear). Possible values: |
| frameborder | Whether the frame should have a border or not. Possible values: |
| marginwidth | Specifies the margin, in pixels, between the frame's contents and it's left and right margins. |
| marginheight | Specifies the margin, in pixels, between the frame's contents and it's top and bottom margins. |
| Other Attributes: |
| Attribute | Description |
| class | Document wide identifier. |
| id | Document wide identifier |
| title | Specifies a title to associate with the element. Many browsers will display this when the cursor hovers over the element (similar to a "tool tip"). |
| style | Inline style (CSS) |
|
Also see the HTML 5 version of HTML tags
Enjoy this page?
-
- Link to this page (copy/paste into your own website or blog):
- Link to Quackit using one of these banner ads.
Thanks for supporting Quackit!