Web Technology Manual
Web Technology Manual
<Doctype html>
<html>
<head>
<title> WEB TECHNOLOGY </title>
</head>
<body>
<p> HTML STYLES </p>
<body style="background-color:yellow;">
<h1 style="color:red;">WEB TECHNOLOGY</h1>
<p style="color:blue">I am implementing Background
design,color,and Text tags in HTML</p>
</body>
</html>
OUTPUT
Department of BCA 1
Web Technology Programs
<Doctype html>
<html>
<head>
<body>
<img src="butterfly.jpg"
width="300px"height="200px">
</body>
</html>
OUTPUT
Department of BCA 2
Web Technology Programs
Department of BCA 3
Web Technology Programs
<li>item2</li></ol>
<dl>
<dt>DESCRIPTION LIST</dt>
<dd>list1</dd>
<dd>list2</dd>
</dl>
</body>
</html>
OUTPUT
Department of BCA 4
Web Technology Programs
Department of BCA 5
Web Technology Programs
<html>
<head><title>table tags</title></head>
<body>
<table border="1">
<thead>
<tr>
<th>NAME</th>
<th>PAPER</th>
<th>MARK</th></tr>
</thead>
<tbody>
<tr>
<td rowspan="2">Harry</td>
<td>core</td>
<td>80</td></tr>
<tr>
<td>allide</td>
<td>90</td></tr>
</tbody>
<tfoot>
<tr>
<td rowspan="2">Mark</td>
<td>core</td>
<td>80</td></tr>
<tr>
<td>allide</td>
<td>75</td>
</tr>
</tfoot>
</table>
</body>
</html>
Department of BCA 6
Web Technology Programs
OUTPUT
Inline Styles:
<Doctype html>
<html>
<head>
<title> WEB TECHNOLOGY </title>
</head>
<p> CASCADING STYLE SHEETS </p>
<p style="color: red; font-size: 16px;">I am using inline styles in css </p>
</body>
</html>
Department of BCA 7
Web Technology Programs
OUTPUT
Internal Styles.
<html>
<style>
p { color: blue;
font-size: 18px;}
</style></head>
<body>
</body>
</html>
Department of BCA 8
Web Technology Programs
OUTPUT:
External Styles:
Department of BCA 9
Web Technology Programs
OUTPUT:
<html>
<head>
<title>Java Script in HTML</title>
<script>
function speak()
{
alert("this is my first javascript program")
}
</script>
</head>
<body>
<button onclick="speak()">click me</button>
</body>
</html>
Department of BCA 10
Web Technology Programs
OUTPUT
Department of BCA 11
Web Technology Programs
<html>
<head>
<title> Hot Text Example</title>
</head>
<body>
<p>click on the college name to find it's website</p>
<p>
<a href="https:www.psgrkcw.ac.in">PSGR KRISHNAMMAL COLLEGE FOR
WOMEN</a>
</p>
</body>
</html>
OUTPUT
Department of BCA 12
Web Technology Programs
<html>
<head>
<title>Frames Example</title>
</head>
<frameset cols="25%,75%">
<frame src="frame1.html"></frame>
<frame src="frame2.html"></frame>
</frameset>
</html>
frame1.html
<html>
<head><title>left frame</title></head>
<body>
<h2>This is left frame</h2>
<p>the left frame content will be displayed here.</p>
</body>
</html>
frame2.html
<html>
<head><title>left frame</title></head>
<body>
<h2>This is right frame</h2>
<p>the right frame content will be displayed here.</p>
</body>
</html>
Department of BCA 13
Web Technology Programs
OUTPUT
<html>
<head>
<title>Form Validations</title>
<style>
body {
font-family: 'Arial', sans-serif;
background-color: #f4f4f4;
margin: 0;
padding: 0;
}
form {
width: 50%;
margin: 50px auto;
padding: 17px;
background-color: #fff;
border-radius: 8px;
Department of BCA 14
Web Technology Programs
label {
display: block;
margin-bottom: 8px;
font-weight: bold;
}
input,
select,
textarea {
width: 100%;
padding: 8px;
margin-bottom: 15px;
border: 1px solid #ccc;
border-radius: 4px;
box-sizing: border-box;
}
input[type="button"] {
background-color: #4559a0;
color: #fff;
cursor: pointer;
}
input[type="button"]:hover {
background-color: #4caf50;
}
</style>
</head>
<body>
<h4><b><center>FORM VALIDATION</center></b></h4>
<form>
<label for="name">Name:</label>
<input type="text" id="name" name="name" required>
Department of BCA 15
Web Technology Programs
<label for="email">Email:</label>
<input type="email" id="email" name="email" required pattern="[a-zA-Z0-
9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}$">
<label for="age">Age:</label>
<input type="number" id="age" name="age" required>
<label for="gender">Gender:</label>
<select id="gender" name="gender" required>
<option value="">Select</option>
<option value="male">Male</option>
<option value="female">Female</option>
<option value="other">Other</option>
</select>
<label for="message">Message:</label>
<textarea id="message" name="message" rows="4" required></textarea>
<script>
function validateForm() {
var name = document.getElementById("name").value;
var email = document.getElementById("email").value;
var age = document.getElementById("age").value;
var gender = document.getElementById("gender").value;
var message = document.getElementById("message").value;
if (name === "" || email === "" || age === "" || gender === "" || message
=== "") {
alert("All fields must be filled out");
return false;
}
Department of BCA 16
Web Technology Programs
return false;
}
return true;
}
</script>
</body>
</html>
OUTPUT
Department of BCA 17
Web Technology Programs
Department of BCA 18
Web Technology Programs
<html>
<head>
<title>pop-up boxes in javascript</title>
</head>
<body>
<center>
<h3>ALERT BOX</h3>
<button onclick="alertbox()">
click here for alert box
</button>
<h3>PROMPT BOX</h3>
<button onclick="promptbox()">
click here for prompt box
</button>
<h3>CONFIRM BOX</h3>
<button onclick="confirmbox()">
click here for confirm box
</button>
<script>
function alertbox(){
alert("This is a alert box")
}
function promptbox(){
prompt("Enter your name")
}
function confirmbox(){
var result = confirm("do you want to procees?")
if (result) {
alert("you clicked ok")
Department of BCA 19
Web Technology Programs
} else {
alert("you clicked cancel")
}
</script>
</center>
</body>
</html>
OUTPUT
Department of BCA 20
Web Technology Programs
Department of BCA 21
Web Technology Programs
<xml>
<person>
<name>John Doe</name>
<age>25</age>
<city>New York</city>
</person>
</xml>
</body>
</html>
Department of BCA 22
Web Technology Programs
OUTPUT
Department of BCA 23