HTML Basics - Lab Manual
Lab 1: Basic HTML Structure
Objective: Learn the structure of an HTML document.
Steps:
1. Open a text editor (e.g., Notepad++, VS Code).
2. Write and save the following as index.html:
<!DOCTYPE html>
<html>
<head>
<title>Lab 1</title>
</head>
<body>
<h1>Welcome to HTML</h1>
<p>This is a basic webpage.</p>
</body>
</html>
3. Open the file in a browser.
Task: Add a <h2> subheading and a new paragraph.
---
Lab 2: Lists and Links
Objective: Practice creating lists and hyperlinks.
Steps:
1. Create an unordered list of your favorite foods.
2. Create an ordered list of steps to cook a meal.
3. Add a link to your favorite recipe website.
Task: Combine lists and links in a single page.
---
Lab 3: Images and Tables
Objective: Learn to use images and tables.
Steps:
1. Add an image to your webpage with appropriate alt text.
2. Create a table to display student names and scores.
Task: Enhance the table by adding a border and a caption.
---
Lab 4: Forms
Objective: Build a form to collect user input.
Steps:
1. Create a form with:
- Name field
- Email field
- Message textarea
- Submit button
2. Style the form with inline CSS.
Task: Add validation for the email field.
---
Lab 5: Final Project
Objective: Build a personal portfolio.
Requirements:
1. Home Page: Include a title, welcome message, and an image.
2. About Page: Use paragraphs and lists to describe yourself.
3. Contact Page: Include a form with text inputs and a submit button.
Submission: Zip the files and share the folder.