search
HomeWeb Front-endHTML TutorialHow to use html frameset tag? Detailed explanation of html frameset tag attributes

html How to use frameset tag? Detailed explanation of the attributes of the html frameset tag. This article mainly describes the definition and usage of the html frameset tag, as well as the uses of the two attributes of the html frameset tag (with examples)

First of all, let us understand what html frameset is. Tag:

html Definition and usage of frameset tag:

frameset element can define a frameset. It is used to organize multiple windows (frames). Each framework has separate documentation. In its simplest application, the frameset element simply specifies how many columns or rows exist in the frameset. You must use cols or rows attributes.

html The role of the frameset tag:

Its role is to specify a frameset for organizing multiple frames and nested framesets.

The FRAMESET element is a container for FRAME elements. An HTML document can contain either a FRAMESET element or a BODY element, but not both.

If a user opens a Web folder in a frame and then clicks something in the Web folder, the clicked file or folder will replace the entire window. For example, suppose a page contains two frames, one pointing to a URL and the second pointing to a network drive. If the user clicks on a file or folder in the second frame, that frame activates the entire window's controls, including the first frame. For file types that the browser cannot handle, such as *.txt files, the corresponding application window will be opened.

Although Web folders are part of the file system hierarchy, this technology does not always represent the actual contents of the file system. A typical example is Network Neighborhood.

html The scope of use of the frameset tag:

This element is available in HTML in Microsoft® Internet Explorer 3.0 and in scripts in Internet Explorer 4.0.

Note: The

tag cannot be used together with the tag. However, if you need to add a tag for browsers that don't support frames, be sure to follow the tag pair within the <noframes> tag before you can use any of the familiar Label. <p><strong>HTML <frameset> tag example: </frameset></strong></p> <p>Simple three-frame page: </p><pre class='brush:php;toolbar:false;'>&lt;html&gt; &lt;frameset cols=&quot;25%,50%,25%&quot;&gt; &lt;frame src=&quot;frame_a.htm&quot; /&gt; &lt;frame src=&quot;frame_b.htm&quot; /&gt; &lt;frame src=&quot;frame_c.htm&quot; /&gt; &lt;/frameset&gt; &lt;/html&gt;</pre><p><strong>html Tips and comments for the frameset tag: </strong></p> <p>Tip: It is important to note that browsers allow users to manually resize the rows or columns of a single frame document, and thus change the relative proportion of each frame in the frame display. Unless you explicitly tell the browser not to do this. To prevent this, you can use the noresize attribute in the <frame> tag. </p> <p>Note: If you wish to validate a page that contains frames, make sure the DTD is set to "Frameset DTD". Read more about XHTML validation. </p> <p>Important: You cannot use the </p> tag with the <frameset></frameset> tag. However, if you need to add a <noframes> tag for browsers that don't support frames, be sure to place the tag within the tag! <p>html Optional attributes of the frameset tag: </p> <p><img src="/static/imghwm/default1.png" data-src="https://img.php.cn//upload/image/223/354/882/1534468985971134.png?x-oss-process=image/resize,p_40" class="lazy" title="1534468985971134.png" alt="How to use html frameset tag? Detailed explanation of html frameset tag attributes"></p> <p><strong>html Standard attributes of the frameset tag: </strong></p> <p>id, class, title, style</p> <p><strong>Cols attribute and rows attribute of HTML <frameset> tag</frameset></strong></p> <p><strong>html Function and usage of frameset tag:</strong># The </p>##<frameset> tag has a required attribute: either rows or cols, depending on your selection, which define the row or column sizes of the frame or nested frameset in the document window. and quantity. <p></p>Both properties accept a quoted, comma-separated list of values ​​that specify the absolute (pixels) or relative (percentage or remaining space) width of the frame (for columns), Or absolute or relative height (for rows). The number of these property values ​​determines how many rows or columns of frames the browser will display in the document window. <p></p>As with tables, the browser will try to display it as close to the given frameset dimensions as possible. However, the browser does not extend the bounds of the document window to accommodate framesets that extend beyond the edges, nor does the browser fill the window with empty space if the specified frame does not fill the entire window. Instead, the browser allocates space based on a frame's size relative to other frames in rows and columns, so that it fills the entire document window. (Did you notice that there are no scroll bars in a main frame document?) <p></p>The following are three examples: <p></p> <p>Example 1<strong></strong></p>The following code A 3-line frame will be created: <p><pre class='brush:php;toolbar:false;'>&lt;frameset rows=&quot;150,300,150&quot;&gt;</pre></p> Each of these lines spans the entire length of the document window. The first and last frames are set to 150 pixels high, and the second row is set to 300 pixels high. <p></p> <p>实际上,除非浏览器窗口正好是 600 像素高,否则浏览器将会自动按照比例延伸或压缩第一和最后一个框架,使得这两个框架都占据 1/4 的窗口空间。中间行将会占据剩下 1/2 的窗口空间。</p> <p><strong>实例2</strong></p> <p>用窗口尺寸的百分比表示的框架行和列尺寸数据更加实际。</p> <p>例如,下面这个示例与刚才那个示例的效果相同:</p><pre class='brush:php;toolbar:false;'>&lt;frameset rows=&quot;25%,50%,25%&quot;&gt;</pre><p>当然,如果这些百分比加起来不是 100%,浏览器也会自动按照比例重新给出每行尺寸以消除差异。</p> <p><strong>实例3</strong></p> <p>如果你像我们一样,那么将问题综合起来就不是一件难事。可能有的框架设计人员正为同样的困难而感到苦恼,这就解释了为什么他们要在 </p> <frameset> 的 rows 和 cols 值上加上星号。它告诉浏览器要在将相邻的框架放入框架集之后,给剩下的空间分配各自的行或列。<p>例如,当浏览器遇到下列框架标签时:</p><pre class='brush:php;toolbar:false;'>&lt;frameset cols=&quot;100, *&quot;&gt;</pre><p>上面的例子会生成一个宽为固定的 100 像素的列,然后再生成另一个框架列,该列会占据框架集中其余所有的空间。</p> <p>【相关推荐】</p> <p><a href="http://www.php.cn/div-tutorial-408459.html" target="_blank" title="HTML <fieldset> 标签的具体用法是什么?怎么用fieldset设置边框颜色?">HTML </a></p> <fieldset> 标签的具体用法是什么?怎么用fieldset设置边框颜色?<br><p><a href="http://www.php.cn/div-tutorial-408527.html" target="_blank" title="html textarea是什么意思?如何获取textarea标签中的换行符和空格?">html textarea是什么意思?如何获取textarea标签中的换行符和空格?</a><br></p> <p><br></p> </fieldset> </frameset> </frameset>

The above is the detailed content of How to use html frameset tag? Detailed explanation of html frameset tag attributes. For more information, please follow other related articles on the PHP Chinese website!

Statement
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Beyond HTML: Essential Technologies for Web DevelopmentBeyond HTML: Essential Technologies for Web DevelopmentApr 26, 2025 am 12:04 AM

To build a website with powerful functions and good user experience, HTML alone is not enough. The following technology is also required: JavaScript gives web page dynamic and interactiveness, and real-time changes are achieved by operating DOM. CSS is responsible for the style and layout of the web page to improve aesthetics and user experience. Modern frameworks and libraries such as React, Vue.js and Angular improve development efficiency and code organization structure.

What are boolean attributes in HTML? Give some examples.What are boolean attributes in HTML? Give some examples.Apr 25, 2025 am 12:01 AM

Boolean attributes are special attributes in HTML that are activated without a value. 1. The Boolean attribute controls the behavior of the element by whether it exists or not, such as disabled disable the input box. 2.Their working principle is to change element behavior according to the existence of attributes when the browser parses. 3. The basic usage is to directly add attributes, and the advanced usage can be dynamically controlled through JavaScript. 4. Common mistakes are mistakenly thinking that values ​​need to be set, and the correct writing method should be concise. 5. The best practice is to keep the code concise and use Boolean properties reasonably to optimize web page performance and user experience.

How can you validate your HTML code?How can you validate your HTML code?Apr 24, 2025 am 12:04 AM

HTML code can be cleaner with online validators, integrated tools and automated processes. 1) Use W3CMarkupValidationService to verify HTML code online. 2) Install and configure HTMLHint extension in VisualStudioCode for real-time verification. 3) Use HTMLTidy to automatically verify and clean HTML files in the construction process.

HTML vs. CSS and JavaScript: Comparing Web TechnologiesHTML vs. CSS and JavaScript: Comparing Web TechnologiesApr 23, 2025 am 12:05 AM

HTML, CSS and JavaScript are the core technologies for building modern web pages: 1. HTML defines the web page structure, 2. CSS is responsible for the appearance of the web page, 3. JavaScript provides web page dynamics and interactivity, and they work together to create a website with a good user experience.

HTML as a Markup Language: Its Function and PurposeHTML as a Markup Language: Its Function and PurposeApr 22, 2025 am 12:02 AM

The function of HTML is to define the structure and content of a web page, and its purpose is to provide a standardized way to display information. 1) HTML organizes various parts of the web page through tags and attributes, such as titles and paragraphs. 2) It supports the separation of content and performance and improves maintenance efficiency. 3) HTML is extensible, allowing custom tags to enhance SEO.

The Future of HTML, CSS, and JavaScript: Web Development TrendsThe Future of HTML, CSS, and JavaScript: Web Development TrendsApr 19, 2025 am 12:02 AM

The future trends of HTML are semantics and web components, the future trends of CSS are CSS-in-JS and CSSHoudini, and the future trends of JavaScript are WebAssembly and Serverless. 1. HTML semantics improve accessibility and SEO effects, and Web components improve development efficiency, but attention should be paid to browser compatibility. 2. CSS-in-JS enhances style management flexibility but may increase file size. CSSHoudini allows direct operation of CSS rendering. 3.WebAssembly optimizes browser application performance but has a steep learning curve, and Serverless simplifies development but requires optimization of cold start problems.

HTML: The Structure, CSS: The Style, JavaScript: The BehaviorHTML: The Structure, CSS: The Style, JavaScript: The BehaviorApr 18, 2025 am 12:09 AM

The roles of HTML, CSS and JavaScript in web development are: 1. HTML defines the web page structure, 2. CSS controls the web page style, and 3. JavaScript adds dynamic behavior. Together, they build the framework, aesthetics and interactivity of modern websites.

The Future of HTML: Evolution and Trends in Web DesignThe Future of HTML: Evolution and Trends in Web DesignApr 17, 2025 am 12:12 AM

The future of HTML is full of infinite possibilities. 1) New features and standards will include more semantic tags and the popularity of WebComponents. 2) The web design trend will continue to develop towards responsive and accessible design. 3) Performance optimization will improve the user experience through responsive image loading and lazy loading technologies.

See all articles

Hot AI Tools

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Undress AI Tool

Undress AI Tool

Undress images for free

Clothoff.io

Clothoff.io

AI clothes remover

Video Face Swap

Video Face Swap

Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Tools

EditPlus Chinese cracked version

EditPlus Chinese cracked version

Small size, syntax highlighting, does not support code prompt function

MantisBT

MantisBT

Mantis is an easy-to-deploy web-based defect tracking tool designed to aid in product defect tracking. It requires PHP, MySQL and a web server. Check out our demo and hosting services.

SAP NetWeaver Server Adapter for Eclipse

SAP NetWeaver Server Adapter for Eclipse

Integrate Eclipse with SAP NetWeaver application server.

mPDF

mPDF

mPDF is a PHP library that can generate PDF files from UTF-8 encoded HTML. The original author, Ian Back, wrote mPDF to output PDF files "on the fly" from his website and handle different languages. It is slower than original scripts like HTML2FPDF and produces larger files when using Unicode fonts, but supports CSS styles etc. and has a lot of enhancements. Supports almost all languages, including RTL (Arabic and Hebrew) and CJK (Chinese, Japanese and Korean). Supports nested block-level elements (such as P, DIV),

MinGW - Minimalist GNU for Windows

MinGW - Minimalist GNU for Windows

This project is in the process of being migrated to osdn.net/projects/mingw, you can continue to follow us there. MinGW: A native Windows port of the GNU Compiler Collection (GCC), freely distributable import libraries and header files for building native Windows applications; includes extensions to the MSVC runtime to support C99 functionality. All MinGW software can run on 64-bit Windows platforms.