Ipdc 2 (Paper)
Ipdc 2 (Paper)
Ipdc 2 (Paper)
Practical : 1 & 2
1
Web Development (3151606) (220760116016)
<html>
<head>
<title>This is my first web page </title>
</head>
<body>
<b>ssasit</b><br>
<i> ssasit </i><br>
<u> ssasit </u><br>
<del> ssasit </del><br>
<p> My name is Krish Gabani. This is my first practical in web development. </p>
<pre>Web development
A html practical program for web development.
</pre>
<center>Web Development</center>
2
Web Development (3151606) (220760116016)
● Heading tags :
Tag Point Size
<h1> 24 pt
<h2> 18 pt
<h3> 12 pt
<h4> 12 pt Bold
<h5> 10 pt
<h6> 7 pt
<html>
<head>
<title> Heading Tags </title>
</head>
<body>
<h1>wd </h1>
<h2> wd </h2>
<h3> wd </h3>
<h4> wd </h4>
<h5> wd </h5>
<h6> wd </h6>
3
Web Development (3151606) (220760116016)
</body> </html>
● List Tag :
Tag Description
<ol> Define an Ordered list
<ul> Define an Unordered list
<li> List item
<dl> Define a definition list
<dt> Define an item in as definition list
<dd> Define a description of an item in a definition list
<html>
<head>
<title> List Tag </title>
</head>
<body>
<h2><b><center>List Tag</center></b>
<h4>List of available courses:</h4>
<ul>
4
Web Development (3151606) (220760116016)
<li>Linked List</li>
<li>Stacks</li>
<li>Queues</li>
</ol>
<h4>Roman Numbers Ordered List :</h4>
<ol type="I">
<li> JavaScript
<ol type="a">
<li>React</li>
<li>Vue.js</li>
</ol></li>
<li>Python
<ol type="a">
<li>Django</li>
<li>Flask</li>
</ol>
</li>
<li>Java</li>
<li>C++</li>
</ol>
<h4>Grocery List :</h4>
<ul type="circle">
<li>Bread</li>
<dl>
<li><dt>Coffee</dt></li>
<dd>- 500 gms</dd>
<li><dt>Milk</dt></li>
<dd>- 1 ltr Tetra Pack</dd>
</dl>
</ul>
</body>
</head>
5
Web Development (3151606) (220760116016)
● Image Tag :
<img> : Display the Image (It have align, src, border, width, height, alt, hspace, vspace etc.
attribute )
6
Web Development (3151606) (220760116016)
</html>
● Hyper link:-
<html>
<head>
<title>hyper link </title>
<body>
<a href="D:\I.T. - 5 SEM\WD\Practical\Practical-1.html"> press hear 1! </a> <br>
<a href="D:\I.T. - 5 SEM\WD\Practical\Practical-1-1.html"> press hear 2! </a> <br>
<a href="D:\I.T. - 5 SEM\WD\Practical\list.html"> press hear 3! </a> <br>
<a href="D:\I.T. - 5 SEM\WD\Practical\image.html"> press hear 4! </a> <br>
<br>
<a href="D:\I.T. - 5 SEM\WD\Practical\student.html">Visit!</a>
</body>
</head>
</html>
7
Web Development (3151606) (220760116016)
● Media tag:-
1.Audio
2.Video
<html>
<head>
<title> Audio And Video </title>
<body>
8
Web Development (3151606) (220760116016)
<br>
<br>
<br>
<br>
<b><h3> Audio Tag </h3></b>
<audio controls>
<source src="C:\Users\krish\Downloads\small-group-laughing-6192.mp3">
</audio>
</body>
</head>
</html>
9
Web Development (3151606) (220760116016)
● Table tag:-
<html>
<head>
<title> Table Tag </title>
</head>
<body>
<table border="width:50%">
<tr>
<th colspan="2">Name</th>
<th>Age</th>
<th>Gender</th>
</tr>
<tr>
<td>KRISH</td>
<td>MEET</td>
<td>19</td>
10
Web Development (3151606) (220760116016)
<tr>
<td>Prins</td>
<td>Yash</td>
<td>25</td>
</tr>
</table>
</body>
</html>
11
Web Development (3151606) (220760116016)
● Frameset tag:-
<html>
<head>
<title>frameset attribute</title>
</head>
12
Web Development (3151606) (220760116016)
● Meta tag:-
<html>
<head>
<meta charset="UTF-8">
<meta name="description" content="Free Web tutorials">
<meta name="keywords" content="HTML,CSS,XML,JavaScript">
<meta name="author" content="John Doe">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
</head>
<body>
<p>All meta information goes in the head section... It is the end of the practical 1 and 2……</p>
</body>
</html>
13
Web Development (3151606) (220760116016)
PRACTICAL :- 3
<html>
14
Web Development (3151606) (220760116016)
<head>
<title> Student Registration Form </title>
</head>
<body>
<h2 align="middle"> Student Registration Form </h2>
<form>
15
Web Development (3151606) (220760116016)
</form>
</body>
</html>
<html>
<head>
<title> railway Registration Form </title>
</head>
<body>
16
Web Development (3151606) (220760116016)
<form>
<option> 17 </option>
<option> 18 </option>
<option> 19 </option>
<option> 20 </option>
<option> 21 </option>
<option> 22 </option>
<option> 23 </option>
<option> 24 </option>
<option> 25 </option>
<option> 26 </option>
<option> 27 </option>
<option> 28 </option>
<option> 29 </option>
<option> 30 </option>
<option> 31 </option>
</select>
<select>
<option> MONTH </option>
<option> 1 </option>
<option> 2 </option>
<option> 3 </option>
<option> 4 </option>
<option> 5 </option>
<option> 6 </option>
<option> 7 </option>
<option> 8 </option>
<option> 9 </option>
<option> 10 </option>
<option> 11 </option>
<option> 12 </option>
</select>
<select>
<option> YEAR </option>
<option> 2024 </option>
<option> 2025 </option>
<option> 2026 </option>
<option> 2027 </option>
</select><br><br>
19
Web Development (3151606) (220760116016)
PRACTICAL :- 4
AIM :- Create a RESUME using HTML and CSS.
<!DOCTYPE html>
20
Web Development (3151606) (220760116016)
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Resume</title>
<style>
body {
font-family: 'Times New Roman';
background-color: #f4f4f4;
margin: 0;
padding: 0;
}
.resume {
max-width: 800px;
margin: 20px auto;
padding: 20px;
background: #fff;
box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
position: relative;
}
header {
text-align: left;
margin-bottom: 20px;
position: relative;
}
header img {
position: absolute;
top: 0;
right: 0;
width: 130px;
height: auto;
border-radius: 50%;
border: 2px solid #333;
}
header h1 {
font-size: 2.5em;
21
Web Development (3151606) (220760116016)
margin: 0;
color: #333;
}
header p {
margin: 5px 0;
font-size: 1.2em;
color: #666;
}
address p {
margin: 5px 0;
font-size: 1em;
color: #444;
}
section {
margin-bottom: 20px;
}
h2 {
border-bottom: 2px solid #333;
padding-bottom: 5px;
font-size: 1.5em;
margin-bottom: 10px;
color: #333;
}
ul {
list-style: disc;
margin: 0;
padding-left: 20px;
}
.job,
.degree {
margin-bottom: 15px;
}
margin: 0;
font-size: 1.2em;
color: #333;
}
.job p,
.degree p {
margin: 5px 0;
color: #666;
}
header h1 {
font-size: 2em;
}
header p {
font-size: 1em;
}
h2 {
font-size: 1.2em;
}
header img {
width: 100px; /* Adjust the size of the photo for smaller screens */
}
}
</style>
</head>
<body>
<div class="resume">
23
Web Development (3151606) (220760116016)
<header>
<img src="D:\I.T. - 5 SEM\WD\Practical\2806146a-8fa3-425b-8793-cf5102ee12ad.jpeg"
alt="KRISH GABANI">
<h1>KRISH GABANI</h1>
<p>Web Developer</p>
<p>Email: <a
href="mailto:krishgabani13@gmail.com">krishgabani13@gmail.com</a></p>
<p>Phone: +91 9510289648</p>
<a href="https://www.linkedin.com/in/krish-gabani-a40045247?
utm_source=share&utm_campaign=share_via&utm_content=profile&utm_medium=android_ap
p">LinkedIn</a>
</header>
<section class="summary">
<h2>Summary</h2>
<p>Enthusiastic and results-driven web developer with 5+ years of experience in
building scalable web applications. Adept at both front-end and back-end technologies, with a
keen eye for detail and a passion for solving complex problems.</p>
</section>
<section class="skills">
<h2>Skills</h2>
<ul>
<li>HTML, CSS, JavaScript</li>
<li>React, Node.js</li>
<li>Python, Django</li>
<li>Git, Docker</li>
</ul>
</section>
<section class="experience">
<h2>Experience</h2>
<div class="job">
<h3>Senior Web Developer</h3>
<p><strong>ABC Corp</strong> | June 2024 - Present</p>
<ul>
<li>Led the development of a high-traffic e-commerce platform, increasing sales by
30%.</li>
<li>Implemented new features and improved existing ones based on client
feedback.</li>
24
Web Development (3151606) (220760116016)
<div class="job">
<h3>Web Developer</h3>
<p><strong>XYZ Inc</strong> | January 2020 - May 2024</p>
<ul>
<li>Developed and maintained company website and intranet.</li>
<li>Optimized web applications for performance and scalability.</li>
<li>Provided technical support and training to team members.</li>
</ul>
</div>
</section>
<section class="education">
<h2>Education</h2>
<div class="degree">
<h3>Gujarat Technological University</h3>
<p><strong>Bachelor of Technology in Information Technology</strong> |
Graduated: 2019</p>
</div>
</section>
</div>
</body>
</html>
25
Web Development (3151606) (220760116016)
PRACTICAL :- 5
26
Web Development (3151606) (220760116016)
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Practical 5</title>
</head>
<body>
<script>
let sum = 0;
const a = [1, 2, 3, 4, 5];
function add() {
for (let i = 0; i < a.length; i++) { // Declare 'i' with 'let'
sum += a[i]; // Use shorthand += for addition
}
document.write("Addition: " + sum + "<br>");
}
add();
alert("Start");
</script>
</body>
</html>
27
Web Development (3151606) (220760116016)
PRACTICAL :- 6
28
Web Development (3151606) (220760116016)
AIM: For the Form created in HTML provide various form values
checking passed by the user.
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Practical 6</title>
<style>
body {
background-color: gray;
font-family: Arial, sans-serif;
color: white;
padding: 20px;
}
label {
display: block;
margin-top: 10px;
}
input {
padding: 8px;
margin-top: 5px;
}
input[type="submit"] {
margin-top: 20px;
}
</style>
</head>
<body>
<h1>Registration Form</h1>
<label for="n3">Password:</label>
<input type="password" id="n3" name="pass"><br>
<label for="n5">Email:</label>
<input type="email" id="n5" name="email"><br>
<script>
function validateForm() {
var a = document.getElementById('nl').value;
var b = document.getElementById('n2').value;
var c = document.getElementById('n3').value;
var d = document.getElementById('n4').value;
var e = document.getElementById('n5').value;
if (a === "" || b === "" || c === "" || d === "" || e === "") {
alert("All the fields are mandatory...");
return false;
} else if (b.length !== 10) {
alert("Contact number should be 10 digits...");
return false;
} else if (isNaN(b)) {
alert("Characters not allowed in contact number...");
return false;
} else if (c !== d) {
alert("Password and confirm password should match...");
return false;
} else if (!isValidEmail(e)) {
alert("Please enter a valid email...");
return false;
} else {
30
Web Development (3151606) (220760116016)
return true;
}
}
function isValidEmail(e) {
var emailRegex = /^[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}$/;
return emailRegex.test(e);
}
</script>
</body>
</html>
PRACTICAL :- 7
31
Web Development (3151606) (220760116016)
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Birthday Countdown</title>
</head>
<body>
<h3>Enter Your Birthday:</h3>
<input type="date" id="bday" />
<button onclick="calculateDays()">Submit</button>
<h1 id="op"></h1>
<script>
function calculateDays() {
const input = document.getElementById('bday').value;
const op = document.getElementById('op');
if (!input) {
op.innerText = "Please select your birthday!";
return;
}
32
Web Development (3151606) (220760116016)
PRACTICAL :- 8
33
Web Development (3151606) (220760116016)
1) Java Script gives the key code for the key pressed.
2) When the key is released the background should change to blue.
<!DOCTYPE html>
<html>
<head>
<title>Practical 8</title>
</head>
<body>
<h1>Changing BG and Text Colour</h1>
<script>
function changeBgColor() {
var selectBgColor = document.getElementById('bgColorSelect').value;
document.body.style.backgroundColor = selectBgColor;
}
function changeTextColor() {
34
Web Development (3151606) (220760116016)
</html>
35