Thursday, April 11, 2019

To show case use of iframes

use of iframes

In the following html code I have showed the use of iframe tag.Note that I have used a html page from my previous code.

In the src attribute of iframe tag you have to change exp5.html with the path of your html page.


<html>
<head>
<title>CSS Task-1</title>
<style>
body {
padding-left:180px;
color: purple;
background-color: #d8da3f; }
.miraj {
list-style-type: none;
padding: 0;
margin: 0;
position:absolute;
top: 32px;
left: 16px;
width: 150px; }

.miraj li {
background: white;
margin: 7px 0;
padding: 5px;
border-right: 15px solid black; }
.miraj a {
text-decoration: none; }
a:link{
     color:blue;
      }
a:visited{
     color:purple;
      }
address {
margin-top: 15px;
padding-top: 15px;
border-top: thin dotted;
  }
iframe{
align:right;
margin-left:700px;
border:none;
height:500px;
width:500px;
background-color:grey;
position:absolute;
}
</style>
</head>

<body>

<ul class="miraj">
<li><a href="https://mirajlimbasia.blogspot.com">Home page</a></li>
<li><a href="https://mirajlimbasia.blogspot.com">Musings</a></li>
<li><a href="https://mirajlimbasia.blogspot.com">My town</a></li>
<li><a href="https://mirajlimbasia.blogspot.com">Links</a></li>
</ul>

<iframe src="exp5.html"></iframe> 
<h1 style="font-family:verdana;">My first styled page</h1>

<p>Welcome to my styled page!</p>

<p>It lacks images, but at least it has style.<br>And it has links, even if they don't goanywhere...</p>
<p>There should be more here, but I don't know what yet.</p>

<address>
Made 5 April 2004<br>by myself.
</address>
 
</body>
</html>

No comments:

Post a Comment

What is XAMPP?

XAMPP is an abbreviation for cross-platform, Apache, MySQL, PHP and Perl, and it allows you to build WordPress site offline, on a local ...