HTML iframe Tag

The HTML iframe is the inline frame within the HTML document which contain another document. The iframe can be added within the text after any line as you may have seen in many Web Site terms and services Web page. The height and width attributes define the size of iframe.

HTML example to show how to insert an iframe in Web page

   1:  <html>
   2:  <head>
   3:  <title>
   4:  How iframes works
   5:  </title>
   6:  </head>
   7:  <body>
   8:  This is an HTML iframe example<br>
   9:  <iframe src="cellpadding.htm" height="40%" width="70%">
  10:  This line will be dispalyed by the browser not supports iframe tag
  11:  </iframe>
  12:  </body>
  13:  </html>

image

HTML code example of iframe with scrolling attribute set to “YES”

   1:  <html>
   2:  <head>
   3:  <title>
   4:  How iframes works
   5:  </title>
   6:  </head>
   7:  <body>
   8:  This is an HTML iframe example<br>
   9:  <iframe src="cellpadding.htm" height="40%" width="70%" scrolling="YES">
  10:  This line will be dispalyed by the browser not supports iframe tag
  11:  </iframe>
  12:  </body>
  13:  </html>

image

Tags: , , , , ,

Author: Revo

Share This Post On

Submit a Comment

Your email address will not be published. Required fields are marked *

four + 14 =

 

Pin It on Pinterest

Shares
Share This