Page 80 - TP-Play_V-2.0_Book-8
P. 80
The <audio> and <video> tags might not work in some browsers that do not support HTML5 and the
file formats.
WAV, MP3, and Ogg are the file formats currently supported to embed audio.
MP4, WebM, and Ogg are the file formats currently supported to embed video.
FRAMES
HTML provides a feature to display more than one web pages on a single screen of the web
browser. These web pages are actually displayed using frames. Frames are the different sections
or parts of a web page. The <IFRAME> tag of HTML allows you to divide a browser window into
many sections or parts. The iframe in HTML stands for Inline Frame. For example,
<IFRAME SRC="url" NAME="description">
Where, URL is the address of a web page which you want to display in a frame. The <IFRAME>
tag provides the following attributes:
✶ SRC: It is used to specify the URL of the web page which you want to display in the frame.
✶ HEIGHT: It is used to specify the height of the frame.
✶ WIDTH: It is used to specify the width of the frame.
✶ NAME: It is used to specify the name of the frame. This name can be used in the TARGET
attribute of the <A> tag.
Let us create a web page using the <IFRAME> tag.
<!DOCTYPE html>
<HTML>
<HEAD>
<TITLE> Frames </TITLE>
</HEAD>
<IFRAME SRC="Home.html" NAME = "iframe1" WIDTH="30%" HEIGHT="100%"
STYLE="float:left;">
</IFRAME>
<IFRAME SRC="Activities.html" NAME="iframe2" WIDTH="70%" HEIGHT="100%"
STYLE="position:absolute;">
</IFRAME>
</HTML>
In the preceding code, we have divided the browser window into two columns. In the left column,
the Home page of the ABC Public School website will open. When we click any hyperlink from the
left column, the linked web page will appear in the right column. Ensure that all the hyperlinks
should contain the TARGET attribute with 'iframe2' as value. Output as shown below:
The float and position properties of CSS are used to display frames side by side. You can also
hide the border of the frames by using the border property of CSS. You can change style of the
border of frames by using the border-style property of CSS.
80 Play (Ver. 2.0)-VIII

