Lab Manual - E-Comm Lab - BBA112
Lab Manual - E-Comm Lab - BBA112
Lab Manual - E-Comm Lab - BBA112
Design a Web page for your Qualification Details in tabular form and
4
also have a link to move to other page. (Table and Linking)
Design a Web page with a heading in blue color text and a paragraph in
5
red color text. (Text Property)
Design a Web page to draw a diagonal line and circle using Canvas in
10
HTML. (Canvas Property)
Tools: Notepad Editor and Web Browser like Internet Explorer or Mozilla Firefox.
THEORY:
1. What is HTML?
A series of tags that are integrated into a text document.
A series of tags that are integrated into a text document.
These look like: <code>formatted text</code> o <code> begins the formatting tag. o
</code> ends the formatting tag.
These tags are then read by a Browser, which translates the tags into the
formatting thatthey represent
2. What are Tags?
HTML tags are used to mark-up HTML elements.
HTML tags are surrounded by the two characters < and >.
The surrounding characters are called angle brackets .
HTML tags normally come in pairs like <b> and </b>.
The first tag in a pair is the start tag; the second tag is the end tag.
The text between the start and end tags is the element content.
HTML tags are not case sensitive; <b> means the same as <B>.
3. Structure Tags In
HTML
HTML Tag
<HTML></HTML>
HEAD Tag
<HEAD></HEAD>
These tags are in the beginning of the document. Important information
is stored in- between these tags including: title, meta-data, styles, and
programming scripts
TITLE Tag
<TITLE></TITLE>
These tags are in-between the HEAD tags and contain the text that appears
in the title of the Web page.
BODY Tag
<BODY></BODY>
As you may have guessed, the BODY tags contain all the text in
the body of the document.
4. Block Level tags
HTML Headings –
Headings are defined with the<h1>
to<h6> tags. Where <h1> -Defines the
largest headings.
<h6> -Defines the smallest headings.
HTML Paragraphs -
Paragraphs are defined with the<p> tag.
Horizontal Rule
The <hr> element is used for horizontal rules that act as dividers
between sections
Tag Description
CONCLUSIONS:
In this way we can use different basic tags of HTML for creating
webpage displaying information.
Practical No. 2
Tools: Notepad Editor and Web Browser like Internet Explorer or Mozilla Firefox.
HTML Program:
<HTML>
<p> This is my experiment with br tag: <br> My Name is: ABC <br> I am the student of
B.Com (H) VI Sem. <br> My college name is KCC College of Legal and Higher
Education <p>
</body>
</HTML>
OUTPUT:
Practical No. 3
Aim: - Design a table to store Student Name, Course Name and Contact Number .
Tools: Notepad Editor and Web Browser like Internet Explorer or Mozilla Firefox.
HTML Program:
<html>
<body bgcolor = "skyblue">
<h4>Table headers:</h4>
<table border="1">
<tr>
<th>Name of student</th>
<th>Course Name</th>
<th>Mobile Number</th>
</tr>
<tr>
<td>Alice</td>
<td>B.Com (H)</td>
<td>9876543210</td>
</tr>
<tr>
<td>Bob</td>
<td>B.Com (H)</td>
<td>9876543211</td>
</tr>
<tr>
<td>Clair</td>
<td>B.Com (H)</td>
<td>9876543212</td>
</tr>
</table>
</body>
</html>
OUTPUT:
Practical No. 4
Aim: - Design a Web page for your Qualification Details in tabular form and also
have a link to move to other page. (Table and Linking)
Tools: Notepad Editor and Web Browser like Internet Explorer or Mozilla Firefox.
HTML Program:
<html>
<body bgcolor = "skyblue">
<h4>Bob's Webpage</h4>
<table border="1">
<br>
<br>
<tr>
<th Colspan = "3">Bob's Qualifications</th>
</tr>
<tr>
<th>Standard</th>
<th>School Name</th>
<th>Grade</th>
</tr>
<tr>
<td>10th</td>
<td>Stephen's Academy</td>
<td>A+</td>
</tr>
<tr>
<td>12th</td>
<td>Stephen's Academy</td>
<td>A+</td>
</tr>
<tr>
<td>B.Com(H)</td>
<td>KCC ILHE (GGSIPU)</td>
<td>A++</td>
</tr>
</table>
</body>
</html>
<html>
<body bgcolor = "skyblue">
</body>
</html>
OUTPUT:
Aim: - Design a Web page with a heading in blue color text and a paragraph in
red color text. (Text Property)
Tools: Notepad Editor and Web Browser like Internet Explorer or Mozilla Firefox.
HTML Program:
<html>
<head>
<style>
body {background-color: powderblue;}
h1 {color: blue;}
p {color:
red;} </style>
</head>
<body>
<h1>This is a heading</h1>
<p>This is a paragraph.</p>
</body>
</html>
OUTPUT:
Practical No. 6
Aim: - Design a Web page with different lists in HTML. (List Property)
Tools: Notepad Editor and Web Browser like Internet Explorer or Mozilla Firefox.
HTML Program:
<html>
<body bgcolor = "skyblue">
<ul>
<li>Coffee</li>
<li>Tea</li>
<li>Milk</li>
</ul>
<ol>
<li>Coffee</li>
<li>Tea</li>
<li>Milk</li>
</ol>
<dl>
<dt>Coffee</dt>
<dd>- black hot drink</dd>
<dt>Milk</dt>
<dd>- white cold drink</dd>
</dl>
</body>
</html>
OUTPUT:
Practical No. 7
Tools: Notepad Editor and Web Browser like Internet Explorer or Mozilla Firefox.
HTML Program:
<html>
<body bgcolor = “Skyblue”>
<h2>HTML Forms</h2>
<form action="/action_page.php">
<label for="fname">First name:</label><br>
<input type="text" id="fname" name="fname"
value="John"><br> <label for="lname">Last name:</label><br>
<input type="text" id="lname" name="lname"
value="Doe"><br><br> <input type="submit" value="Submit">
</form>
<p>If you click the "Submit" button, the form-data will be sent to a page
called "/action_page.php".</p>
</body>
</html>
OUTPUT:
Practical No. 8
Aim: - Design a Web page to upload a music file on it and play automatically when
the webpage loads. (Audio Property)
Tools: Notepad Editor and Web Browser like Internet Explorer or Mozilla Firefox.
HTML Program:
<html>
<body bgcolor = "SkyBlue">
</body>
</html>
OUTPUT:
Practical No. 9
Aim: - Design a Web page to get and post location. (Geolocation Property)
Tools: Notepad Editor and Web Browser like Internet Explorer or Mozilla Firefox.
HTML Program:
<html>
<body bgcolor = "SkyBlue">
<p id="demo"></p>
<script>
var x = document.getElementById("demo");
function getLocation() {
if (navigator.geolocation) {
navigator.geolocation.getCurrentPosition(showPosition);
} else {
x.innerHTML = "Geolocation is not supported by this browser.";
}
}
function showPosition(position) {
x.innerHTML = "Latitude: " + position.coords.latitude +
"<br>Longitude: " + position.coords.longitude;
}
</script>
</body>
</html>
OUTPUT:
Practical No. 10
Aim: - Design a Web page to draw a diagonal line and circle using Canvas in
HTML. (Canvas Property)
Tools: Notepad Editor and Web Browser like Internet Explorer or Mozilla Firefox.
HTML Program:
<html>
<body bgcolor = "SkyBlue">
solid #d3d3d3;">
Your browser does not support the HTML canvas tag.</canvas>
<script>
var c = document.getElementById("myCanvas");
var ctx = c.getContext("2d");
ctx.moveTo(0,0);
ctx.lineTo(200,100);
ctx.stroke();
</script>
<br>
<br>
<br>
<br>
<script>
var c = document.getElementById("myCanvas");
var ctx = c.getContext("2d");
ctx.beginPath();
ctx.arc(95,50,40,0,2*Math.PI);
ctx.stroke();
</script>
</body>
</html>
OUTPUT:
Practical No. 11
Aim: - Design a Web page to draw “Hello World” using Canvas in HTML.
(Canvas Property)
Tools: Notepad Editor and Web Browser like Internet Explorer or Mozilla Firefox.
HTML Program:
<html>
#d3d3d3;"> Your browser does not support the HTML canvas tag.</canvas>
<script>
var c =
</script>
</body>
</html>
OUTPUT:
Practical No. 12
Tools: Notepad Editor and Web Browser like Internet Explorer or Mozilla Firefox.
HTML Program:
<HTML>
<Title> My Website </Title>
<Body BGcolor = “Teal”>
<H1> This is my Educatonal Website </H1>
<table border="1">
<tr>
<th colspan = "3"> Students Registered With Us:
</th> <tr>
<th>Name of student</th>
<th>Course Name</th>
<th>Mobile Number</th>
</tr>
<tr>
<td>Alice</td>
<td>B.Com (H)</td>
<td>9876543210</td>
</tr>
<p> To Know About Bob, Click on the Name: <P>
<tr>
<td><a href = "F:\KCC\Lab Manuual - E-Commerce Lab\Web
Pages\Program4.html"> Bob </a>
</td>
<td>B.Com (H)</td>
<td>9876543211</td>
</tr>
<tr>
<td>Clair</td>
<td>B.Com (H)</td>
<td>9876543212</td>
</tr>
<br>
</table>
type="audio/mpeg">
</audio>
<p id="demo"></p>
<script>
var x = document.getElementById("demo");
function getLocation() {
if (navigator.geolocation) {
navigator.geolocation.getCurrentPosition(showPosition);
} else {
x.innerHTML = "Geolocation is not supported by this browser.";
}
}
function showPosition(position) {
x.innerHTML = "Latitude: " + position.coords.latitude +
"<br>Longitude: " + position.coords.longitude;
}
</script>
</body>
</HTML>
OUTPUT: