Vous êtes sur la page 1sur 10

Internet Techanology Enrollment No:130320708504

1
L J I E T
Internet Technology (710205)

Aim: Write HTML program that demonstrates the use of image as hyperlink.
< ! DOCTYPE html>
<html>
<body>
<p>Create a link of an image:
<a href="default.asp">
<img src="smiley.gif" alt="HTML tutorial" width="32" height="32"></a></p>
<p>No border around the image, but still a link:
<a href="default.asp">
<img border="0" src=smiley.gif alt=HTML Tutorial width=32 height=32>
</a> </p>
</body>
</html>
How the HTML code above looks in a browser:
Create a link of an image:
No border around the image, but still a link:















Internet Techanology Enrollment No:130320708504

2
L J I E T
Aim: Write HTML to display Library Book information in table format.
<!DOCTYPE html>
<html>
<body>
<table border="1">
<tr>
<th>BOOK TAG NUMBER</th>
<th>BOOK NAME</th>
<th>BOOK AUTHOR</th>
</tr>
<tr>
<td>01307</td>
<td>Heat and Thermodynamics</td>
<td>Brijlal N. Subramanyam</td>
</tr>
<tr>
<td>01308</td>
<td>CAD/CAM & AUTOMATION</td>
<td>FarazdakHaideri</td>
</tr>
</table>
</body>
</html>
How the HTML code above looks in a browser:

BOOK TAG NUMBER BOOK NAME BOOK AUTHOR
01307 Heat and Thermodynamics Brijlal N. Subramanyam
01308 CAD/CAM & AUTOMATION FarazdakHaideri










Internet Techanology Enrollment No:130320708504

3
L J I E T

Aim:Write HTML code for frameset and frame tags.
<HTML>
<HEAD>
<TITLE>Great Recipes</TITLE>
</HEAD>

<FRAMESET ROWS="15%,*">
<FRAME SRC="recipetitlebar.html" NAME=TITLE SCROLLING=NO>

<FRAMESET COLS="20%,*">
<FRAME SRC="recipesidebar.html" NAME=SIDEBAR>
<FRAME SRC="recipes.html" NAME=RECIPES>
</FRAMESET>
</FRAMESET>

</HTML>


How the HTML code above looks in a browser:























Internet Techanology Enrollment No:130320708504

4
L J I E T
Aim: Write HTML code to display ordered list.
<! DOCTYPE html>
<html>
<body>
<h4>An Ordered List :< /h4>
<ol>
<li>Coffee</li>
<li>Tea</li>
<li>Milk</li>
</ol>
</body>
</html>
How the HTML code above looks in a browser:

An Ordered List:
1. Coffee
2. Tea
3. Milk




















Internet Techanology Enrollment No:130320708504

5
L J I E T
Aim: Using the CSS display paragraphs with black border, yellow
background and red color for text.

<! DOCTYPE html>
<html>
<head>
<style>
p.three
{
border- style: solid;
border- width: 1px;
border-color: black;
}
Body
{
Background-color:yellow;
}
Body{color:red}
</style>
</head>
<body>
<p class="three">this is an ordinary paragraph. Notice that this text is red.The
default text-color for a page is defind in the body selector. </p>
</body>
</html>
How the HTML code above looks in a browser:







Internet Techanology Enrollment No:130320708504

6
L J I E T

Aim: Using the CSS to display a fixed background image (this image will not
scroll with the rest of the page).
<!DOCTYPE html>
<html>
<head>
<style>
body
{
background-image:url('Chrysanthemum.jpg');
background-color:aqua;
}
</style>
</head>

<body>
<h1>CAD/CAM</h1>
</body>

</html>


How the HTML code above looks in a browser:










Internet Techanology Enrollment No:130320708504

7
L J I E T
Aim: Write a Java script function which is triggered on button click event
and it should display current date and time.
<! DOCTYPE html>
<html>
<head>
<script>
function displayDate()
{
document.getElementById("demo").innerHTML=Date();
}
</script>
</head>
<body>
<h1>My First JavaScript</h1>
<p id="demo">This is a paragraph.</p>
<button type="button" onclick="displayDate()">Display Date</button>
</body>
</html>
Output: My First JavaScript
This is a paragraph.

Just click on display date the following output is shown below:
Tue Nov 19 2013 21:58:47 GMT+0530 (India Standard Time)
Display Date
Internet Techanology Enrollment No:130320708504

8
L J I E T
Aim: Write a Java script to validate the content of textbox1 and textbox2 and
calculate sum of those two numbers if content is valid otherwise display
appropriate message.


Student.Xml:-
<?xml version="1.0"?>
<!DOCTYPE STUDENTS SYSTEM "E:\XML1\STUDENT.dtd">
<STUDENTS>
<STUDENT>
<STUDENTDATA>
<NAME> SUTHA </NAME>
<ID> 2007IT51 </ID>
<AGE> 20 </AGE>
<ADDRESS> 12,SATHY ROAD,GOBI </ADDRESS>
</STUDENTDATA>
</STUDENT>
</STUDENTS>
How the HTML code above looks in a browser:
SUTHA 2007IT51 20
12,SATHY ROAD,GOBI


Student.dtd:-
<?xml version="1.0"?>
<!ELEMENT STUDENTS (STUDENT*)>
<!ELEMENT STUDENT (STUDENTDATA*)>
<!ELEMENT STUDENTDATA (NAME,ID,AGE,ADDRESS)>
<!ELEMENT NAME (#PCDATA)>
<!ELEMENT ID (#PCDATA)>
<!ELEMENT AGE (#PCDATA)>
<!ELEMENT ADDRESS (#PCDATA)>





Internet Techanology Enrollment No:130320708504

9
L J I E T
Aim: Write a Java script to change HTML elements.
<! DOCTYPE html>
<html>
<body>
<h1>My First Web Page</h1>
<p id="demo">My First Paragraph.</p>
<script>
document.getElementById("demo").innerHTML="My First JavaScript";
</script>
</body>
</html>
Output: My First Web Page
My First JavaScript












Internet Techanology Enrollment No:130320708504

10
L J I E T
Aim: Create an XML document to display student information.

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "E:\XML1\STUDENT.dtd"">
<html>
<head COLOR:RED><h1 style="color:red">
<MARQUEE DIRECTION="RIGHT"><CENTER> COLLEGE OF ENGINEERING AND TECHNOLOGY </CENTER>
</MARQUEE> </H1>
<title> STUDENT DETAILS DISPLAY </title>
</head>
<body style="background-color:PINK"> <H2 STYLE="COLOR: BLUE">
<MARQUEE><CENTER>DEPARTMENT OF INFORMATION TECHNOLOGY </CENTER>
</MARQUEE><BR></H2>
<MARQUEE DIRECTION="DOWN"><H3 STYLE= "COLOR:GREEN"><CENTER>FINAL IT STUDENTS DETAILS
</CENTER></MARQUEE><BR><BR></H3>
<CENTER><TABLE BORDER="1">
<THEAD>
<TR>
<TH> NAME </TH>
<TH> ID </TH>
<TH> AGE </TH>
<TH> ADDRESS </TH>
</TR>
</THEAD>
<TFOOT>
<TR>
<TH COLSPAN="4"> STUDENT CATALOG</TH>
</TFOOT>
<TR>
<TD>SUTHA </TD>
<TD>2007IT51</TD>
<TD>20</TD>
<TD>12,SATHY ROAD,GOBI</TD>
</TR>
</TABLE></CENTER>
</body>
</html>
How the HTML code above looks in a browser:

Vous aimerez peut-être aussi