Gagan As1

Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 26

WDD LAB FILE

ASSIGNMENT:1 HTML
Q1: Write a paragraph in html using various tags and alignment.
Coding:
<html>
<head>
<title> ques1 </title>
</head>
<body>
<p> this is a paragraph </p>
<b> Hello </b> <br>
<i> Hello </i> <br>
<u> Hello </u>
<br>
<small> Hello </small>
<br>
<big> Hello </big> <br>
<mark> hello </mark> <br>
<del> hello </del> <br>
<pre> this is used to preserve spaces </pre>
<em> Hello </em> <br>
A <sub> subscript </sub> <br>
A <sup> superscript </sup>
<br>
<p align="right">
GAGAN NISHAL
BCAM
01490301913

WDD LAB FILE

right aligned para </p>


</body>
</html>
Output:

GAGAN NISHAL
BCAM
01490301913

WDD LAB FILE

Q2: Write a code in HTML to display the following

Ax2+Bx+C=0
2H2+O2=2H2O

Coding:
<html>
<head>
<title>Ques 2</title>
</head>
<body>
A x<sup>2</sup> + B x + C = 0
<br>
2 H<sub>2</sub> + O<sub>2</sub> = 2 H<sub>2</sub>O
</body>
</html>
Output:

GAGAN NISHAL
BCAM
01490301913

WDD LAB FILE

Q3: Create a webpage describing yourself


a) Use pre tag for sub heading.
b) Use I tag wherever you are using number.
c) Use b and u tag for address.
Coding:
<html>
<head> <title> Myself </title> </head>
<body>
<pre>
<u> Myself </u>
<u> Name </u>
Gagan
<u> Phone </u>
<i> 9310251600 </i>
<u> Address </u>
<b> <u> Patel Nagar, south ex, New Delhi </u> </b>
</pre>
</body>
</html>
Output:

GAGAN NISHAL
BCAM
01490301913

WDD LAB FILE

Q4: Create a web page that uses various attributes of font.


Coding:
<html>
<head> </head>
<body>
<font face="arial" color="blue" size="26">
Hello
</font>
Welcome
</body>
</html>
Output:

GAGAN NISHAL
BCAM
01490301913

WDD LAB FILE

Q5: Write a code to display the names 9 planets using different types of unordered lists.
Coding:
<html>
<head> <title> q5 </title> </head>
<body> PLANETS
<ul type="circle">
<li> mercury </li>
<li> venus </li>
<li> earth </li> </ul>
<ul type="square">
<li> mars </li>
<li> jupiter </li>
GAGAN NISHAL
BCAM
01490301913

WDD LAB FILE

<li> saturn </li>


</ul>
<ul type="disc">
<li> uranus</li>
<li> neptune</li>
<li> pluto </li>
</ul>
</body>
</html>

Output:

GAGAN NISHAL
BCAM
01490301913

WDD LAB FILE

Q6: Write a code to display the different courses available in your institute. Show the use of
different types of ordered lists.
GAGAN NISHAL
BCAM
01490301913

WDD LAB FILE

Coding:
<html>
<head> <title> Ordered list </title> </head>
<body> <u> IT Courses:
<ol type="1">
<li> Bca </li>
<li> Mca </li> </ol>
<u> Management courses:
<ol type="A">
<li> bcom </li>
<li> Mba </li>
<li> Bba </li> </ol>
</body>
</html>
Output:

Q7: Write a code for creating definition list that shows beverages with description.
GAGAN NISHAL
BCAM
01490301913

WDD LAB FILE

Coding:
<html>
<head> <title> definition list </title> </head>
<body>
DEFINITION LIST :
<dl>
<dt> Tea </dt>
<dd> A drink made with tea leaves. </dd>
<dt> Coffee </dt>
<dd> A drink made with cocoa. </dd>
</dl>
</body>
</html>
Output:

GAGAN NISHAL
BCAM
01490301913

WDD LAB FILE

Q8: Write an html code to display the syllabus off bba(cam) v, clicking on each subject should
open its description in a new document.
Coding:
<html>
<head>
<title> Ques 8 </title>
</head>
<body> BCAM subjects and syllabus: <br>
<ul> <li> <a href = "file2.html"> WDD </a> </li>
<li> <a href = "file3.html"> Consumer behaviour </a> </li>
<li> <a href = "file4.html"> MIS </a> </li>
<li> <a href = "file5.html"> Business policy </a> </li>
</ul>
</body>
File2:
</html>
<html>
<body>
WDD syllabus contains:
<ol>
<li> Introduction to WWW </li>
<li> conceps of web technology </li>
<li> web browsers </li>
<li> internet and intranet </li>
<li> protocols</li>
GAGAN NISHAL
BCAM
01490301913

WDD LAB FILE

<li> html</li>
<li> tables frames forms </li>
<li> java script www history </li>
<li> dreamweaver </li>
<li> flash </li>
</ol>
</body>
</html>
Output:

GAGAN NISHAL
BCAM
01490301913

WDD LAB FILE

Q9: Write html code to insert two images aligned left and right. Also change the background
color to black and give a suitable heading to the web page.
Coding:
<html>
<head> <title> IMAGE insertion </title> </head>
<body bgcolor="black"> <font color="pink"> <b> <center> My LIFE in two pictures &#9786;
&hearts;</center> <b> </font>
<img src="a.jpg" align="left">
<img src="b.jpg" height="380" width="460" align="right">
</body>
</html>
Output:

Q10: Insert an image in a document and link it to some other page.


Coding:
<html>
GAGAN NISHAL
BCAM
01490301913

WDD LAB FILE

<head>
<title> image insertion and linking </title>
</head>
<body>
<a href="q4.html">
<img src="img2.jpg" height="242" width="340"> </a>
</body>
</html>
Q4.html:
<html>
<body>
<font face="arial" color="blue" size="26">
Hello
</font>
Welcome
</body>
</html>

Output:

GAGAN NISHAL
BCAM
01490301913

WDD LAB FILE

Q11: Create a table containing s.no, name and marks of 10 students.


GAGAN NISHAL
BCAM
01490301913

WDD LAB FILE

Coding:
<TABLE border="1">
<TR><TH>Sno.<TH> NAME <TH> MARKS </TR>
<TR> <TD> 1 <TD> NITIKA <TD> 80 </TR>
<TR> <TD> 2 <TD> DEVYANI <TD> 60 </TR>
<TR> <TD> 3 <TD> RAJNI <TD> 90 </TR>
<TR> <TD> 4 <TD> GAURAV <TD> 70 </TR>
</TABLE>

Output:

Q13: Create a webpage showing the usage of marquee tag attributes.


GAGAN NISHAL
BCAM
01490301913

WDD LAB FILE

Coding:
<html>
<head> <title> Marquee </title> </head>
<body>
<marquee height="80" width-"60" bgcolor="pink" direction="up"
loop="10"> Hello and welcome </marquee>
</body>
</html>
Output:

GAGAN NISHAL
BCAM
01490301913

WDD LAB FILE

Q14: Create a webpage displaying the table with 4 cells- 1st cell should consist of unordered list
of subjects in 4th sem, 2nd cell should consist of some image, 3rd cell should show the usage of
anchor tag and 4th tag should contain some text with background color as blue.
Coding:
<html>
<head>
<title> table </title>
<body>
<table border="2">
<tr> <td> This cell contains a list.
<ul>
<li> Mango </li>
<li> Apple </li>
</ul> </td>
<td> This cell contains an image.
<img src="mango.jpg">
</td>
</tr>
<tr>
<td> This cell contains htyperlink
<a href="q4.html"> click </a>
<td bgcolor="blue">
welcome
</td>
</tr>
</table>
GAGAN NISHAL
BCAM
01490301913

WDD LAB FILE

</body>
</html
Output:

Q15:- Create a website which shows the usage of navigation frames.


GAGAN NISHAL
BCAM
01490301913

WDD LAB FILE

Coding:
<html>
<frameset cols="20%,80%">
<frame src="file.html" name="frame1">
<frame name="frame2">
</frameset>
</html>
File.html
<html>
<body>
<a href="file2.html" target="frame2"> click here </a>
</body>
</html>
File2.html
<html>
<body bgcolor="skyblue">
<center> <h3> HELLO WELCOME TO OUR PAGE </h3>
<img src="Hydrangeas.jpg">
</center>
</body>
</html>

Output:
GAGAN NISHAL
BCAM
01490301913

WDD LAB FILE

GAGAN NISHAL
BCAM
01490301913

WDD LAB FILE

Q17: Create a registration form using different elements of form tag.


Coding:
<html>
<head> <title> 17 form </title> </head>
<body>
<form> <pre>
First name <input type="text" name="firstname">

Password <input type="password">

Gender:
male

<input type="radio" name="gender" value="male"> female <input type="radio"

name="gender" value="female">

Vehicle:
Bikes <input type="checkbox" name="vehicle" value="bikes"> Cars <input type="checkbox"

name="vehicle" value="car">

select your age: <select>


<option> 19 </option>
<option> 18 </option>
GAGAN NISHAL
BCAM
01490301913

WDD LAB FILE

<option> 17 </option>
<option> 16 </option>
</select>

<input type="submit"> <input type="reset">


</pre>
</body>
</html>
Output:

Q18: Create a webpage to implement hr tag along with all its attributes.
Coding:
GAGAN NISHAL
BCAM
01490301913

WDD LAB FILE

<html>
<head> <title> q18 </title> </head>
<body>
WELCOME
<hr align="left" size="2" width="1009">
The program shows the use of hr tag.
</body>
</html>
Output:

GAGAN NISHAL
BCAM
01490301913

WDD LAB FILE

Q19: Create a webpage to implement special characters in html.


Coding:
<html>
<head> <title> Symbols </title> </head>
<body> SPECIAL CHARACTERS: <br>
&copy; <br>
&and; <br>
&hearts; <br>
&ang; <br>
&amp; <br>
</body>
</html>
Output:

GAGAN NISHAL
BCAM
01490301913

WDD LAB FILE

Q20: Create a webpage to show the usage of email link.


Coding:
<html>
<head>
<title> email link </title>
</head>
<body>
<a href = "mailto: [email protected]"> Email </a>
</body>
</html>
Output:

GAGAN NISHAL
BCAM
01490301913

You might also like