Monday, 21 September 2015

Frameset in HTML

Frameset in HTML :-

  • Let understand the concept of frameset with a suitable example:-

frameset.html:-

<!DOCTYPE html>
<html>

<frameset rows="10%, 50%">
  <frame src="frame1.html" noresize="noresize">
<frameset cols="20%, 80%">
  <frame src="frame2.html" noresize="noresize">
  <frame src="frame3.html" noresize="noresize">
</frameset>
</frameset>
</html>



frame1.html:-

<!DOCTYPE html>
<html>

<body bgcolor="lightpink">
  <marquee><b><i><h1>Header of the page</h1></i></b></marquee>
</body>
</html>

           

frame2.html:-

<!DOCTYPE html>
<html>

<body bgcolor="lightblue">
<br/><br/><br/><br/><br/><br/><br/><br/><br/><br/><br/><br/><br/><br/>
<b><i><h1>Side Info. of the page</h1></i></b>
</body>
</html>
             


frame3.html:-

<!DOCTYPE html>
<html>

<body brcolor="lightgrey">
<br/><br/><br/><br/><br/><br/><br/><br/><br/><br/><br/><br/><br/><br/>
<center><b><i><h1>Content of the page</h1></i></b></center>

</body>
</html>
             


Screenshot:-

              



Description:-

           The frameset concept of HTML, is basically used when the developer wants to divide the web page in different section, by using "<frameset>" tag. In this each section, the data can be displayed by using the "<frame>" tag, declared under the frameset tag. "<src>" attribute of the "<frame>" tag is used to provide link of the HTML file.