What are Frames in HTML

In this article we will discuss about the frames in HTML.
  • 2018

Frames are used to divide the HTML document into sub windows or we can say frames. It provides the user with multiview at a time on the screen. To create the frames in HTML <frameset> tag is used in HTML document. Here the frame is divided in the form of two columns. From left hand side the column width is 75% and Remaining is 25%.

HTML code:

<html>
<head>
<title>Frameset page<title>
</head>
<frameset cols = "75%, *">
  <frame src="file1.html"></frame>
  <frame src="file2.html"></frame>
</frameset>
</html>

Here <frameset cols="75%,*"> means that HTML document is divided into two columns one is of 75% widths and other is of remaining width i.e. 25%. It can take another form as well.

<html>
<head>
<title>Frameset page<title>
</head>
<frameset cols = "75%, 25%">
  <frame src="file1.html"></frame>
  <frame src="file2.html"></frame>
</frameset>
</html>

Here we have taken 25% in place of star(*). We can do this as well.

Ask Your Question 
 
Got a programming related question? You may want to post your question here
 

Categories

More Articles

© 2019 DotNetHeaven. All rights reserved.